bt2: add `if __name__ == '__main__'` snippet to all tests
[babeltrace.git] / tests / bindings / python / bt2 / test_component_class.py
index 98fc91dbb9b7f8de675a95a59e71f66b40542fbd..92d051f7ee8a1224a1474caf6d2deb750a6f4de1 100644 (file)
@@ -326,7 +326,7 @@ class ComponentClassTestCase(unittest.TestCase):
         graph = bt2.Graph()
         comp = graph.add_component(MySink, 'salut')
         self._comp_cls = comp.cls
-        self.assertTrue(issubclass(type(self._comp_cls), bt2._SinkComponentClass))
+        self.assertIs(type(self._comp_cls), bt2._SinkComponentClassConst)
 
     def tearDown(self):
         del self._py_comp_cls
@@ -358,3 +358,7 @@ class ComponentClassTestCase(unittest.TestCase):
         ).query()
         expected = ['an object', {'yes': 'no', 'book': -17}, 23]
         self.assertEqual(res, expected)
+
+
+if __name__ == '__main__':
+    unittest.main()
This page took 0.023846 seconds and 4 git commands to generate.