python -m unittest mypkg.tests.test_module.TestClass.test_method
# from command line
# module_name and method_name are self - explanatory
# MyTestClass is the class derived from unittest.TestCase (for example)
python -m unittest module_name.MyTestClass.method_name
class Test(unittest.TestCase):
def test_if_other_test_passes(self):
# Add first test here
self.assertTrue(foo())
# This test will only run if the first test passes
self.assertEqual(bar(), 2)