def test_importlib_import_absolute_srv(self):
# Verify that files exists and are importable
# __import__ checks sys.modules by itself
# but the test is not reflecting anything if we use the already loaded module.
if sys.modules.get('std_srvs.srv'):
#TODO : EVERYWHERE !
raise unittest.SkipTest("module previously loaded".format('std_srvs.srv'))
else:
std_srvs = importlib.__import__('std_srvs.srv')
std_srvs = std_srvs.srv
self.assert_std_service_classes(std_srvs.SetBool, std_srvs.SetBoolRequest, std_srvs.SetBoolResponse)
评论列表
文章目录