From 1a3ced3f45423d79e08ca7d861e8118e8618d3b2 Mon Sep 17 00:00:00 2001 From: "Chris St. Pierre" Date: Fri, 5 Oct 2012 11:57:16 -0400 Subject: wrote more detailed unit testing documentation --- .../Testsrc/Testlib/TestClient/TestTools/TestPOSIX/TestDevice.py | 4 +--- .../Testlib/TestClient/TestTools/TestPOSIX/TestDirectory.py | 4 +--- .../Testsrc/Testlib/TestClient/TestTools/TestPOSIX/TestFile.py | 4 +--- .../Testsrc/Testlib/TestClient/TestTools/TestPOSIX/TestHardlink.py | 4 +--- .../Testlib/TestClient/TestTools/TestPOSIX/TestNonexistent.py | 4 +--- .../Testsrc/Testlib/TestClient/TestTools/TestPOSIX/TestSymlink.py | 4 +--- .../Testsrc/Testlib/TestClient/TestTools/TestPOSIX/Test__init.py | 4 +--- .../Testsrc/Testlib/TestClient/TestTools/TestPOSIX/Testbase.py | 7 +++---- testsuite/Testsrc/Testlib/TestEncryption.py | 3 +-- testsuite/Testsrc/Testlib/TestOptions.py | 4 +--- testsuite/Testsrc/Testlib/TestServer/TestPlugin/Testbase.py | 3 +-- testsuite/Testsrc/Testlib/TestServer/TestPlugin/Testexceptions.py | 3 +-- testsuite/Testsrc/Testlib/TestServer/TestPlugin/Testhelpers.py | 7 ++++--- testsuite/Testsrc/Testlib/TestServer/TestPlugin/Testinterfaces.py | 3 +-- .../TestServer/TestPlugins/TestCfg/TestCfgCheetahGenerator.py | 4 +--- .../TestPlugins/TestCfg/TestCfgEncryptedCheetahGenerator.py | 2 +- .../TestServer/TestPlugins/TestCfg/TestCfgEncryptedGenerator.py | 4 +--- .../TestPlugins/TestCfg/TestCfgEncryptedGenshiGenerator.py | 4 +--- .../TestPlugins/TestCfg/TestCfgExternalCommandVerifier.py | 4 +--- .../TestServer/TestPlugins/TestCfg/TestCfgGenshiGenerator.py | 4 +--- .../Testlib/TestServer/TestPlugins/TestCfg/TestCfgInfoXML.py | 4 +--- .../Testsrc/Testlib/TestServer/TestPlugins/TestCfg/Test_init.py | 4 +--- testsuite/Testsrc/Testlib/TestServer/TestPlugins/TestMetadata.py | 6 +++--- testsuite/Testsrc/Testlib/TestServer/TestPlugins/TestProbes.py | 4 +--- testsuite/Testsrc/Testlib/TestServer/TestPlugins/TestProperties.py | 4 +--- testsuite/Testsrc/Testlib/TestServer/TestPlugins/TestSEModules.py | 4 +--- .../Testsrc/Testlib/TestServer/TestPlugins/TestTemplateHelper.py | 3 +-- 27 files changed, 34 insertions(+), 75 deletions(-) (limited to 'testsuite/Testsrc/Testlib') diff --git a/testsuite/Testsrc/Testlib/TestClient/TestTools/TestPOSIX/TestDevice.py b/testsuite/Testsrc/Testlib/TestClient/TestTools/TestPOSIX/TestDevice.py index a18327fe0..9f396b0b6 100644 --- a/testsuite/Testsrc/Testlib/TestClient/TestTools/TestPOSIX/TestDevice.py +++ b/testsuite/Testsrc/Testlib/TestClient/TestTools/TestPOSIX/TestDevice.py @@ -16,9 +16,7 @@ while path != "/": path = os.path.dirname(path) from Test__init import get_posix_object from Testbase import TestPOSIXTool -from common import XI_NAMESPACE, XI, inPy3k, call, builtins, u, can_skip, \ - skip, skipIf, skipUnless, Bcfg2TestCase, DBModelTestCase, syncdb, \ - patchIf, datastore +from common import * class TestPOSIXDevice(TestPOSIXTool): test_obj = POSIXDevice diff --git a/testsuite/Testsrc/Testlib/TestClient/TestTools/TestPOSIX/TestDirectory.py b/testsuite/Testsrc/Testlib/TestClient/TestTools/TestPOSIX/TestDirectory.py index e01bd7453..1ce6562c5 100644 --- a/testsuite/Testsrc/Testlib/TestClient/TestTools/TestPOSIX/TestDirectory.py +++ b/testsuite/Testsrc/Testlib/TestClient/TestTools/TestPOSIX/TestDirectory.py @@ -17,9 +17,7 @@ while path != "/": path = os.path.dirname(path) from Test__init import get_posix_object from Testbase import TestPOSIXTool -from common import XI_NAMESPACE, XI, inPy3k, call, builtins, u, can_skip, \ - skip, skipIf, skipUnless, Bcfg2TestCase, DBModelTestCase, syncdb, \ - patchIf, datastore +from common import * class TestPOSIXDirectory(TestPOSIXTool): test_obj = POSIXDirectory diff --git a/testsuite/Testsrc/Testlib/TestClient/TestTools/TestPOSIX/TestFile.py b/testsuite/Testsrc/Testlib/TestClient/TestTools/TestPOSIX/TestFile.py index cdf11ce5e..f69c33a97 100644 --- a/testsuite/Testsrc/Testlib/TestClient/TestTools/TestPOSIX/TestFile.py +++ b/testsuite/Testsrc/Testlib/TestClient/TestTools/TestPOSIX/TestFile.py @@ -20,9 +20,7 @@ while path != "/": path = os.path.dirname(path) from Test__init import get_posix_object from Testbase import TestPOSIXTool -from common import XI_NAMESPACE, XI, inPy3k, call, builtins, u, can_skip, \ - skip, skipIf, skipUnless, Bcfg2TestCase, DBModelTestCase, syncdb, \ - patchIf, datastore +from common import * def get_file_object(posix=None): if posix is None: diff --git a/testsuite/Testsrc/Testlib/TestClient/TestTools/TestPOSIX/TestHardlink.py b/testsuite/Testsrc/Testlib/TestClient/TestTools/TestPOSIX/TestHardlink.py index d68e15837..c38e86aeb 100644 --- a/testsuite/Testsrc/Testlib/TestClient/TestTools/TestPOSIX/TestHardlink.py +++ b/testsuite/Testsrc/Testlib/TestClient/TestTools/TestPOSIX/TestHardlink.py @@ -16,9 +16,7 @@ while path != "/": path = os.path.dirname(path) from Test__init import get_posix_object from Testbase import TestPOSIXTool -from common import XI_NAMESPACE, XI, inPy3k, call, builtins, u, can_skip, \ - skip, skipIf, skipUnless, Bcfg2TestCase, DBModelTestCase, syncdb, \ - patchIf, datastore +from common import * class TestPOSIXHardlink(TestPOSIXTool): test_obj = POSIXHardlink diff --git a/testsuite/Testsrc/Testlib/TestClient/TestTools/TestPOSIX/TestNonexistent.py b/testsuite/Testsrc/Testlib/TestClient/TestTools/TestPOSIX/TestNonexistent.py index 375ff00eb..676b18f5d 100644 --- a/testsuite/Testsrc/Testlib/TestClient/TestTools/TestPOSIX/TestNonexistent.py +++ b/testsuite/Testsrc/Testlib/TestClient/TestTools/TestPOSIX/TestNonexistent.py @@ -16,9 +16,7 @@ while path != "/": path = os.path.dirname(path) from Test__init import get_config, get_posix_object from Testbase import TestPOSIXTool -from common import XI_NAMESPACE, XI, inPy3k, call, builtins, u, can_skip, \ - skip, skipIf, skipUnless, Bcfg2TestCase, DBModelTestCase, syncdb, \ - patchIf, datastore +from common import * class TestPOSIXNonexistent(TestPOSIXTool): test_obj = POSIXNonexistent diff --git a/testsuite/Testsrc/Testlib/TestClient/TestTools/TestPOSIX/TestSymlink.py b/testsuite/Testsrc/Testlib/TestClient/TestTools/TestPOSIX/TestSymlink.py index b02f7b3c3..4c8ddfa3f 100644 --- a/testsuite/Testsrc/Testlib/TestClient/TestTools/TestPOSIX/TestSymlink.py +++ b/testsuite/Testsrc/Testlib/TestClient/TestTools/TestPOSIX/TestSymlink.py @@ -16,9 +16,7 @@ while path != "/": path = os.path.dirname(path) from Test__init import get_posix_object from Testbase import TestPOSIXTool -from common import XI_NAMESPACE, XI, inPy3k, call, builtins, u, can_skip, \ - skip, skipIf, skipUnless, Bcfg2TestCase, DBModelTestCase, syncdb, \ - patchIf, datastore +from common import * class TestPOSIXSymlink(TestPOSIXTool): test_obj = POSIXSymlink diff --git a/testsuite/Testsrc/Testlib/TestClient/TestTools/TestPOSIX/Test__init.py b/testsuite/Testsrc/Testlib/TestClient/TestTools/TestPOSIX/Test__init.py index 14a2520df..e503ebd38 100644 --- a/testsuite/Testsrc/Testlib/TestClient/TestTools/TestPOSIX/Test__init.py +++ b/testsuite/Testsrc/Testlib/TestClient/TestTools/TestPOSIX/Test__init.py @@ -14,9 +14,7 @@ while path != "/": if os.path.basename(path) == "testsuite": break path = os.path.dirname(path) -from common import XI_NAMESPACE, XI, inPy3k, call, builtins, u, can_skip, \ - skip, skipIf, skipUnless, Bcfg2TestCase, DBModelTestCase, syncdb, \ - patchIf, datastore +from common import * def get_config(entries): config = lxml.etree.Element("Configuration") diff --git a/testsuite/Testsrc/Testlib/TestClient/TestTools/TestPOSIX/Testbase.py b/testsuite/Testsrc/Testlib/TestClient/TestTools/TestPOSIX/Testbase.py index bcb1d16af..39c0b02d0 100644 --- a/testsuite/Testsrc/Testlib/TestClient/TestTools/TestPOSIX/Testbase.py +++ b/testsuite/Testsrc/Testlib/TestClient/TestTools/TestPOSIX/Testbase.py @@ -17,9 +17,7 @@ while path != "/": break path = os.path.dirname(path) from Test__init import get_posix_object -from common import XI_NAMESPACE, XI, inPy3k, call, builtins, u, can_skip, \ - skip, skipIf, skipUnless, Bcfg2TestCase, DBModelTestCase, syncdb, \ - patchIf, datastore +from common import * try: import selinux @@ -33,6 +31,7 @@ try: except ImportError: HAS_ACLS = False + class TestPOSIXTool(Bcfg2TestCase): test_obj = POSIXTool @@ -52,7 +51,7 @@ class TestPOSIXTool(Bcfg2TestCase): # fully_specified should do no checking on the abstract # POSIXTool object self.assertTrue(self.ptool.fully_specified(Mock())) - + @patch('os.stat') @patch('os.walk') @patch("Bcfg2.Client.Tools.POSIX.base.%s._verify_metadata" % diff --git a/testsuite/Testsrc/Testlib/TestEncryption.py b/testsuite/Testsrc/Testlib/TestEncryption.py index 530592cd0..7e9d910d8 100644 --- a/testsuite/Testsrc/Testlib/TestEncryption.py +++ b/testsuite/Testsrc/Testlib/TestEncryption.py @@ -13,8 +13,7 @@ while path != "/": if os.path.basename(path) == "testsuite": break path = os.path.dirname(path) -from common import call, u, can_skip, skip, skipIf, skipUnless, \ - Bcfg2TestCase, patchIf +from common import * try: from Bcfg2.Encryption import * diff --git a/testsuite/Testsrc/Testlib/TestOptions.py b/testsuite/Testsrc/Testlib/TestOptions.py index e20a320b1..dc91a499b 100644 --- a/testsuite/Testsrc/Testlib/TestOptions.py +++ b/testsuite/Testsrc/Testlib/TestOptions.py @@ -13,9 +13,7 @@ while path != '/': if os.path.basename(path) == "testsuite": break path = os.path.dirname(path) -from common import XI_NAMESPACE, XI, inPy3k, call, builtins, u, can_skip, \ - skip, skipIf, skipUnless, Bcfg2TestCase, DBModelTestCase, syncdb, \ - patchIf, datastore +from common import * class TestDefaultConfigParser(Bcfg2TestCase): @patch("%s.ConfigParser.get" % ConfigParser.__name__) diff --git a/testsuite/Testsrc/Testlib/TestServer/TestPlugin/Testbase.py b/testsuite/Testsrc/Testlib/TestServer/TestPlugin/Testbase.py index 4b2f1981f..7ee3697bb 100644 --- a/testsuite/Testsrc/Testlib/TestServer/TestPlugin/Testbase.py +++ b/testsuite/Testsrc/Testlib/TestServer/TestPlugin/Testbase.py @@ -13,8 +13,7 @@ while path != '/': if os.path.basename(path) == "testsuite": break path = os.path.dirname(path) -from common import call, builtins, skip, skipIf, skipUnless, Bcfg2TestCase, \ - patchIf, datastore +from common import * class TestDebuggable(Bcfg2TestCase): diff --git a/testsuite/Testsrc/Testlib/TestServer/TestPlugin/Testexceptions.py b/testsuite/Testsrc/Testlib/TestServer/TestPlugin/Testexceptions.py index d2b72251e..916ce822d 100644 --- a/testsuite/Testsrc/Testlib/TestServer/TestPlugin/Testexceptions.py +++ b/testsuite/Testsrc/Testlib/TestServer/TestPlugin/Testexceptions.py @@ -12,8 +12,7 @@ while path != '/': if os.path.basename(path) == "testsuite": break path = os.path.dirname(path) -from common import call, builtins, skip, skipIf, skipUnless, Bcfg2TestCase, \ - patchIf, datastore +from common import * class TestPluginInitError(Bcfg2TestCase): diff --git a/testsuite/Testsrc/Testlib/TestServer/TestPlugin/Testhelpers.py b/testsuite/Testsrc/Testlib/TestServer/TestPlugin/Testhelpers.py index 27d726fbb..8a1d5a949 100644 --- a/testsuite/Testsrc/Testlib/TestServer/TestPlugin/Testhelpers.py +++ b/testsuite/Testsrc/Testlib/TestServer/TestPlugin/Testhelpers.py @@ -17,11 +17,11 @@ while path != '/': if os.path.basename(path) == "testsuite": break path = os.path.dirname(path) -from common import XI_NAMESPACE, XI, call, builtins, skip, skipIf, \ - skipUnless, Bcfg2TestCase, patchIf, datastore, inPy3k, can_skip, re_type +from common import * from TestServer.TestPlugin.Testbase import TestPlugin, TestDebuggable from TestServer.TestPlugin.Testinterfaces import TestGenerator + def tostring(el): return lxml.etree.tostring(el, xml_declaration=False).decode('UTF-8') @@ -155,12 +155,13 @@ class TestDirectoryBacked(Bcfg2TestCase): # such thing as a bad event def test_child_interface(self): - # ensure that the child object has the correct interface + """ ensure that the child object has the correct interface """ self.assertTrue(hasattr(self.test_obj.__child__, "HandleEvent")) def get_obj(self, fam=None): if fam is None: fam = Mock() + @patch("%s.%s.add_directory_monitor" % (self.test_obj.__module__, self.test_obj.__name__), Mock()) diff --git a/testsuite/Testsrc/Testlib/TestServer/TestPlugin/Testinterfaces.py b/testsuite/Testsrc/Testlib/TestServer/TestPlugin/Testinterfaces.py index 6ef40d385..ace509057 100644 --- a/testsuite/Testsrc/Testlib/TestServer/TestPlugin/Testinterfaces.py +++ b/testsuite/Testsrc/Testlib/TestServer/TestPlugin/Testinterfaces.py @@ -14,8 +14,7 @@ while path != '/': if os.path.basename(path) == "testsuite": break path = os.path.dirname(path) -from common import call, builtins, skip, skipIf, skipUnless, Bcfg2TestCase, \ - patchIf, datastore +from common import * from TestServer.TestPlugin.Testbase import TestPlugin diff --git a/testsuite/Testsrc/Testlib/TestServer/TestPlugins/TestCfg/TestCfgCheetahGenerator.py b/testsuite/Testsrc/Testlib/TestServer/TestPlugins/TestCfg/TestCfgCheetahGenerator.py index 2577b29df..1832e5e03 100644 --- a/testsuite/Testsrc/Testlib/TestServer/TestPlugins/TestCfg/TestCfgCheetahGenerator.py +++ b/testsuite/Testsrc/Testlib/TestServer/TestPlugins/TestCfg/TestCfgCheetahGenerator.py @@ -13,9 +13,7 @@ while path != "/": if os.path.basename(path) == "testsuite": break path = os.path.dirname(path) -from common import XI_NAMESPACE, XI, inPy3k, call, builtins, u, can_skip, \ - skip, skipIf, skipUnless, Bcfg2TestCase, DBModelTestCase, syncdb, \ - patchIf, datastore, re_type +from common import * from TestServer.TestPlugins.TestCfg.Test_init import TestCfgGenerator diff --git a/testsuite/Testsrc/Testlib/TestServer/TestPlugins/TestCfg/TestCfgEncryptedCheetahGenerator.py b/testsuite/Testsrc/Testlib/TestServer/TestPlugins/TestCfg/TestCfgEncryptedCheetahGenerator.py index 539b1e741..46062569d 100644 --- a/testsuite/Testsrc/Testlib/TestServer/TestPlugins/TestCfg/TestCfgEncryptedCheetahGenerator.py +++ b/testsuite/Testsrc/Testlib/TestServer/TestPlugins/TestCfg/TestCfgEncryptedCheetahGenerator.py @@ -11,7 +11,7 @@ while path != "/": if os.path.basename(path) == "testsuite": break path = os.path.dirname(path) -from common import can_skip, skipUnless +from common import * try: from TestServer.TestPlugins.TestCfg.TestCfgCheetahGenerator import \ diff --git a/testsuite/Testsrc/Testlib/TestServer/TestPlugins/TestCfg/TestCfgEncryptedGenerator.py b/testsuite/Testsrc/Testlib/TestServer/TestPlugins/TestCfg/TestCfgEncryptedGenerator.py index 7e4a64996..71a7410da 100644 --- a/testsuite/Testsrc/Testlib/TestServer/TestPlugins/TestCfg/TestCfgEncryptedGenerator.py +++ b/testsuite/Testsrc/Testlib/TestServer/TestPlugins/TestCfg/TestCfgEncryptedGenerator.py @@ -14,9 +14,7 @@ while path != "/": if os.path.basename(path) == "testsuite": break path = os.path.dirname(path) -from common import XI_NAMESPACE, XI, inPy3k, call, builtins, u, can_skip, \ - skip, skipIf, skipUnless, Bcfg2TestCase, DBModelTestCase, syncdb, \ - patchIf, datastore, re_type +from common import * from TestServer.TestPlugins.TestCfg.Test_init import TestCfgGenerator diff --git a/testsuite/Testsrc/Testlib/TestServer/TestPlugins/TestCfg/TestCfgEncryptedGenshiGenerator.py b/testsuite/Testsrc/Testlib/TestServer/TestPlugins/TestCfg/TestCfgEncryptedGenshiGenerator.py index 0375b8928..b447a9bb8 100644 --- a/testsuite/Testsrc/Testlib/TestServer/TestPlugins/TestCfg/TestCfgEncryptedGenshiGenerator.py +++ b/testsuite/Testsrc/Testlib/TestServer/TestPlugins/TestCfg/TestCfgEncryptedGenshiGenerator.py @@ -12,9 +12,7 @@ while path != "/": if os.path.basename(path) == "testsuite": break path = os.path.dirname(path) -from common import XI_NAMESPACE, XI, inPy3k, call, builtins, u, can_skip, \ - skip, skipIf, skipUnless, Bcfg2TestCase, DBModelTestCase, syncdb, \ - patchIf, datastore, re_type +from common import * try: from TestServer.TestPlugins.TestCfg.TestCfgGenshiGenerator import \ diff --git a/testsuite/Testsrc/Testlib/TestServer/TestPlugins/TestCfg/TestCfgExternalCommandVerifier.py b/testsuite/Testsrc/Testlib/TestServer/TestPlugins/TestCfg/TestCfgExternalCommandVerifier.py index fde7ed722..11dbdd391 100644 --- a/testsuite/Testsrc/Testlib/TestServer/TestPlugins/TestCfg/TestCfgExternalCommandVerifier.py +++ b/testsuite/Testsrc/Testlib/TestServer/TestPlugins/TestCfg/TestCfgExternalCommandVerifier.py @@ -14,9 +14,7 @@ while path != "/": if os.path.basename(path) == "testsuite": break path = os.path.dirname(path) -from common import XI_NAMESPACE, XI, inPy3k, call, builtins, u, can_skip, \ - skip, skipIf, skipUnless, Bcfg2TestCase, DBModelTestCase, syncdb, \ - patchIf, datastore, re_type +from common import * from TestServer.TestPlugins.TestCfg.Test_init import TestCfgVerifier diff --git a/testsuite/Testsrc/Testlib/TestServer/TestPlugins/TestCfg/TestCfgGenshiGenerator.py b/testsuite/Testsrc/Testlib/TestServer/TestPlugins/TestCfg/TestCfgGenshiGenerator.py index 2dd647352..baad10933 100644 --- a/testsuite/Testsrc/Testlib/TestServer/TestPlugins/TestCfg/TestCfgGenshiGenerator.py +++ b/testsuite/Testsrc/Testlib/TestServer/TestPlugins/TestCfg/TestCfgGenshiGenerator.py @@ -14,9 +14,7 @@ while path != "/": if os.path.basename(path) == "testsuite": break path = os.path.dirname(path) -from common import XI_NAMESPACE, XI, inPy3k, call, builtins, u, can_skip, \ - skip, skipIf, skipUnless, Bcfg2TestCase, DBModelTestCase, syncdb, \ - patchIf, datastore, re_type +from common import * from TestServer.TestPlugins.TestCfg.Test_init import TestCfgGenerator diff --git a/testsuite/Testsrc/Testlib/TestServer/TestPlugins/TestCfg/TestCfgInfoXML.py b/testsuite/Testsrc/Testlib/TestServer/TestPlugins/TestCfg/TestCfgInfoXML.py index 88dd1f18f..839e9c3b8 100644 --- a/testsuite/Testsrc/Testlib/TestServer/TestPlugins/TestCfg/TestCfgInfoXML.py +++ b/testsuite/Testsrc/Testlib/TestServer/TestPlugins/TestCfg/TestCfgInfoXML.py @@ -14,9 +14,7 @@ while path != "/": if os.path.basename(path) == "testsuite": break path = os.path.dirname(path) -from common import XI_NAMESPACE, XI, inPy3k, call, builtins, u, can_skip, \ - skip, skipIf, skipUnless, Bcfg2TestCase, DBModelTestCase, syncdb, \ - patchIf, datastore, re_type +from common import * from TestServer.TestPlugins.TestCfg.Test_init import TestCfgInfo diff --git a/testsuite/Testsrc/Testlib/TestServer/TestPlugins/TestCfg/Test_init.py b/testsuite/Testsrc/Testlib/TestServer/TestPlugins/TestCfg/Test_init.py index 11f06873d..8cfd69242 100644 --- a/testsuite/Testsrc/Testlib/TestServer/TestPlugins/TestCfg/Test_init.py +++ b/testsuite/Testsrc/Testlib/TestServer/TestPlugins/TestCfg/Test_init.py @@ -16,9 +16,7 @@ while path != "/": if os.path.basename(path) == "testsuite": break path = os.path.dirname(path) -from common import XI_NAMESPACE, XI, inPy3k, call, builtins, u, can_skip, \ - skip, skipIf, skipUnless, Bcfg2TestCase, DBModelTestCase, syncdb, \ - patchIf, datastore, re_type +from common import * from TestPlugin import TestSpecificData, TestEntrySet, TestGroupSpool, \ TestPullTarget diff --git a/testsuite/Testsrc/Testlib/TestServer/TestPlugins/TestMetadata.py b/testsuite/Testsrc/Testlib/TestServer/TestPlugins/TestMetadata.py index 13e514e77..5610d9071 100644 --- a/testsuite/Testsrc/Testlib/TestServer/TestPlugins/TestMetadata.py +++ b/testsuite/Testsrc/Testlib/TestServer/TestPlugins/TestMetadata.py @@ -18,12 +18,11 @@ while path != "/": if os.path.basename(path) == "testsuite": break path = os.path.dirname(path) -from common import XI_NAMESPACE, XI, inPy3k, call, builtins, u, can_skip, \ - skip, skipIf, skipUnless, Bcfg2TestCase, DBModelTestCase, syncdb, \ - patchIf, datastore +from common import * from TestPlugin import TestXMLFileBacked, TestMetadata as _TestMetadata, \ TestStatistics, TestDatabaseBacked + def get_clients_test_tree(): return lxml.etree.XML(''' @@ -47,6 +46,7 @@ def get_clients_test_tree(): ''').getroottree() + def get_groups_test_tree(): return lxml.etree.XML(''' diff --git a/testsuite/Testsrc/Testlib/TestServer/TestPlugins/TestProbes.py b/testsuite/Testsrc/Testlib/TestServer/TestPlugins/TestProbes.py index 0ad92ca72..a1d41b693 100644 --- a/testsuite/Testsrc/Testlib/TestServer/TestPlugins/TestProbes.py +++ b/testsuite/Testsrc/Testlib/TestServer/TestPlugins/TestProbes.py @@ -15,9 +15,7 @@ while path != "/": if os.path.basename(path) == "testsuite": break path = os.path.dirname(path) -from common import XI_NAMESPACE, XI, inPy3k, call, builtins, u, can_skip, \ - skip, skipIf, skipUnless, Bcfg2TestCase, DBModelTestCase, syncdb, \ - patchIf, datastore +from common import * from Bcfg2.Server.Plugins.Probes import * from TestPlugin import TestEntrySet, TestProbing, TestConnector, \ TestDatabaseBacked diff --git a/testsuite/Testsrc/Testlib/TestServer/TestPlugins/TestProperties.py b/testsuite/Testsrc/Testlib/TestServer/TestPlugins/TestProperties.py index 883e88ba1..fb4773d75 100644 --- a/testsuite/Testsrc/Testlib/TestServer/TestPlugins/TestProperties.py +++ b/testsuite/Testsrc/Testlib/TestServer/TestPlugins/TestProperties.py @@ -14,9 +14,7 @@ while path != "/": if os.path.basename(path) == "testsuite": break path = os.path.dirname(path) -from common import XI_NAMESPACE, XI, inPy3k, call, builtins, u, can_skip, \ - skip, skipIf, skipUnless, Bcfg2TestCase, DBModelTestCase, syncdb, \ - patchIf, datastore +from common import * from TestPlugin import TestStructFile, TestConnector, TestPlugin, \ TestDirectoryBacked diff --git a/testsuite/Testsrc/Testlib/TestServer/TestPlugins/TestSEModules.py b/testsuite/Testsrc/Testlib/TestServer/TestPlugins/TestSEModules.py index e18e2bfd6..8a148b353 100644 --- a/testsuite/Testsrc/Testlib/TestServer/TestPlugins/TestSEModules.py +++ b/testsuite/Testsrc/Testlib/TestServer/TestPlugins/TestSEModules.py @@ -14,9 +14,7 @@ while path != "/": if os.path.basename(path) == "testsuite": break path = os.path.dirname(path) -from common import XI_NAMESPACE, XI, inPy3k, call, builtins, u, can_skip, \ - skip, skipIf, skipUnless, Bcfg2TestCase, DBModelTestCase, syncdb, \ - patchIf, datastore +from common import * from TestPlugin import TestSpecificData, TestGroupSpool diff --git a/testsuite/Testsrc/Testlib/TestServer/TestPlugins/TestTemplateHelper.py b/testsuite/Testsrc/Testlib/TestServer/TestPlugins/TestTemplateHelper.py index 18855a631..832857601 100644 --- a/testsuite/Testsrc/Testlib/TestServer/TestPlugins/TestTemplateHelper.py +++ b/testsuite/Testsrc/Testlib/TestServer/TestPlugins/TestTemplateHelper.py @@ -13,8 +13,7 @@ while path != "/": if os.path.basename(path) == "testsuite": break path = os.path.dirname(path) -from common import call, skip, skipIf, skipUnless, Bcfg2TestCase, patchIf, \ - datastore +from common import * from TestPlugin import TestDirectoryBacked, TestConnector, TestPlugin, \ TestFileBacked -- cgit v1.2.3-1-g7c22