diff options
Diffstat (limited to 'meta/lib')
-rw-r--r-- | meta/lib/oeqa/runtime/cases/go.py | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/meta/lib/oeqa/runtime/cases/go.py b/meta/lib/oeqa/runtime/cases/go.py new file mode 100644 index 0000000000..89ba2c3ecb --- /dev/null +++ b/meta/lib/oeqa/runtime/cases/go.py | |||
@@ -0,0 +1,19 @@ | |||
1 | # | ||
2 | # SPDX-License-Identifier: MIT | ||
3 | # | ||
4 | |||
5 | from oeqa.runtime.case import OERuntimeTestCase | ||
6 | from oeqa.core.decorator.depends import OETestDepends | ||
7 | from oeqa.runtime.decorator.package import OEHasPackage | ||
8 | |||
9 | class GoHelloworldTest(OERuntimeTestCase): | ||
10 | @OETestDepends(['ssh.SSHTest.test_ssh']) | ||
11 | @OEHasPackage(['go-helloworld']) | ||
12 | def test_gohelloworld(self): | ||
13 | cmd = "go-helloworld" | ||
14 | status, output = self.target.run(cmd) | ||
15 | msg = 'Exit status was not 0. Output: %s' % output | ||
16 | self.assertEqual(status, 0, msg=msg) | ||
17 | |||
18 | msg = 'Incorrect output: %s' % output | ||
19 | self.assertEqual(output, "Hello, Go examples!", msg=msg) | ||