1 from os.path
import dirname, basename, isfile
5 modules = glob.glob(dirname(__file__)+
"/*.py")
6 __all__ = [ basename(f)[:-3]
for f
in modules
if isfile(f)
and not f.endswith(
'__init__.py')]
11 super(RosparamTestSuite, self).
__init__()
15 for test_module
in __all__:
16 module = __import__(
"tests."+test_module, fromlist=[
'*'])
17 for name
in dir(module):
18 obj = getattr(module, name)
19 if isinstance(obj, type)
and issubclass(obj, unittest.TestCase):
20 testcases[name] = unittest.TestLoader().loadTestsFromTestCase(obj)
23 for test_name, test
in testcases.items():