test_perl_dbd_mysql.py 885 B

1234567891011121314151617181920212223242526272829303132
  1. from tests.package.test_perl import TestPerlBase
  2. import os
  3. class TestPerlDBDmysql(TestPerlBase):
  4. """
  5. package:
  6. DBD-mysql XS
  7. direct dependencies:
  8. DBI XS
  9. """
  10. config = TestPerlBase.config + \
  11. """
  12. BR2_PACKAGE_PERL=y
  13. BR2_PACKAGE_PERL_DBD_MYSQL=y
  14. BR2_TARGET_ROOTFS_EXT2=y
  15. BR2_TARGET_ROOTFS_EXT2_SIZE="120M"
  16. """
  17. def login(self):
  18. ext2_file = os.path.join(self.builddir, "images", "rootfs.ext2")
  19. self.emulator.boot(arch="armv5",
  20. kernel="builtin",
  21. options=["-drive", "file=%s,if=scsi,format=raw" % ext2_file],
  22. kernel_cmdline=["rootwait", "root=/dev/sda"])
  23. self.emulator.login()
  24. def test_run(self):
  25. self.login()
  26. self.module_test("DBI")
  27. self.module_test("DBD::mysql")