perl.py 535 B

1234567891011121314151617
  1. #
  2. # SPDX-License-Identifier: MIT
  3. #
  4. import os
  5. from oeqa.runtime.case import OERuntimeTestCase
  6. from oeqa.core.decorator.depends import OETestDepends
  7. from oeqa.runtime.decorator.package import OEHasPackage
  8. class PerlTest(OERuntimeTestCase):
  9. @OETestDepends(['ssh.SSHTest.test_ssh'])
  10. @OEHasPackage(['perl'])
  11. def test_perl_works(self):
  12. status, output = self.target.run("perl -e '$_=\"Uryyb, jbeyq\"; tr/a-zA-Z/n-za-mN-ZA-M/;print'")
  13. self.assertEqual(status, 0)
  14. self.assertEqual(output, "Hello, world")