commit a51d61d2c00cd9f24456ac47c36004aa1de88903 Author: Pierre-Yves Chibon pingou@pingoured.fr Date: Thu Aug 2 11:34:12 2012 +0200
Fix the tests
Fix the import of pkgdb-cli so that the tests can actually run
test.py | 7 ++++--- 1 files changed, 4 insertions(+), 3 deletions(-) --- diff --git a/test.py b/test.py index 76b3044..faa8d6d 100644 --- a/test.py +++ b/test.py @@ -4,8 +4,10 @@ from fedora.client import PackageDB import unittest import logging +import imp + +pkgdb = imp.load_source('pkgdb', 'pkgdb-cli')
-pkgdb = __import__('pkgdb-cli')
class testPkgdDBCli(unittest.TestCase): @@ -25,7 +27,6 @@ class testPkgdDBCli(unittest.TestCase): out = pkgdb.get_package_info('guake', 'all', True, True)
def testGetPackages(self): - pass pkgdb.get_packages('R-*', branch='all') pkgdb.get_packages('R-*', branch='devel')
@@ -70,7 +71,7 @@ def suite(): if __name__ == '__main__':
suiteFew = unittest.TestSuite() - suiteFew.addTest(testPkgdDBCli("testgetPackageInfo")) + suiteFew.addTest(testPkgdDBCli("testGetPackageInfo")) suiteFew.addTest(testPkgdDBCli("testGetOrphanedPackages")) suiteFew.addTest(testPkgdDBCli("testGetPackagerInfo")) suiteFew.addTest(testPkgdDBCli("testOrphanPackage"))
packagedb-cli-commits@lists.stg.fedorahosted.org