diff options
Diffstat (limited to 'meta/lib/oeqa/runtime/cases/go.py')
-rw-r--r-- | meta/lib/oeqa/runtime/cases/go.py | 21 |
1 files changed, 21 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..39a80f4dca --- /dev/null +++ b/meta/lib/oeqa/runtime/cases/go.py | |||
@@ -0,0 +1,21 @@ | |||
1 | # | ||
2 | # Copyright OpenEmbedded Contributors | ||
3 | # | ||
4 | # SPDX-License-Identifier: MIT | ||
5 | # | ||
6 | |||
7 | from oeqa.runtime.case import OERuntimeTestCase | ||
8 | from oeqa.core.decorator.depends import OETestDepends | ||
9 | from oeqa.runtime.decorator.package import OEHasPackage | ||
10 | |||
11 | class GoHelloworldTest(OERuntimeTestCase): | ||
12 | @OETestDepends(['ssh.SSHTest.test_ssh']) | ||
13 | @OEHasPackage(['go-helloworld']) | ||
14 | def test_gohelloworld(self): | ||
15 | cmd = "go-helloworld" | ||
16 | status, output = self.target.run(cmd) | ||
17 | msg = 'Exit status was not 0. Output: %s' % output | ||
18 | self.assertEqual(status, 0, msg=msg) | ||
19 | |||
20 | msg = 'Incorrect output: %s' % output | ||
21 | self.assertEqual(output, "Hello, world!", msg=msg) | ||