Brad Bishop | c342db3 | 2019-05-15 21:57:59 -0400 | [diff] [blame^] | 1 | # |
| 2 | # SPDX-License-Identifier: MIT |
| 3 | # |
| 4 | |
Brad Bishop | 6e60e8b | 2018-02-01 10:27:11 -0500 | [diff] [blame] | 5 | import os |
| 6 | |
| 7 | from oeqa.runtime.case import OERuntimeTestCase |
Andrew Geissler | 99467da | 2019-02-25 18:54:23 -0600 | [diff] [blame] | 8 | from oeqa.core.decorator.depends import OETestDepends |
Brad Bishop | 6e60e8b | 2018-02-01 10:27:11 -0500 | [diff] [blame] | 9 | from oeqa.runtime.decorator.package import OEHasPackage |
| 10 | |
| 11 | class PerlTest(OERuntimeTestCase): |
Andrew Geissler | 99467da | 2019-02-25 18:54:23 -0600 | [diff] [blame] | 12 | @OETestDepends(['ssh.SSHTest.test_ssh']) |
Brad Bishop | 1a4b7ee | 2018-12-16 17:11:34 -0800 | [diff] [blame] | 13 | @OEHasPackage(['perl']) |
Brad Bishop | 6e60e8b | 2018-02-01 10:27:11 -0500 | [diff] [blame] | 14 | def test_perl_works(self): |
Brad Bishop | 1a4b7ee | 2018-12-16 17:11:34 -0800 | [diff] [blame] | 15 | status, output = self.target.run("perl -e '$_=\"Uryyb, jbeyq\"; tr/a-zA-Z/n-za-mN-ZA-M/;print'") |
| 16 | self.assertEqual(status, 0) |
| 17 | self.assertEqual(output, "Hello, world") |