before run_test_method: self.case.__dict__.keys() ['exception_handlers', '_testMethodName', '_TestCase__details', '_resultForDoCleanups', '_unique_id_gen', '_traceback_id_gens', '_cleanups', '_type_equality_funcs', 'cmd', '_TestCase__exception_handlers', '_TestCase__setup_called', '_testMethodDoc', '_TestCase__teardown_called', '_TestCase__RunTest']
after: (Pdb) self.case.__dict__.keys() ['exception_handlers', '_testMethodName', '_TestCase__details', '_resultForDoCleanups', '_unique_id_gen', '_traceback_id_gens', '_cleanups', '_type_equality_funcs', 'cmd', '_TestCase__exception_handlers', '_TestCase__setup_called', '_testMethodDoc', '_TestCase__teardown_called', '_TestCase__RunTest']
after tearDown:
(Pdb) self.case.__dict__.keys() ['exception_handlers', '_testMethodName', '_TestCase__details', '_resultForDoCleanups', '_unique_id_gen', '_traceback_id_gens', '_cleanups', '_type_equality_funcs', '_TestCase__exception_handlers', '_TestCase__setup_called', '_testMethodDoc', '_TestCase__teardown_called', '_TestCase__RunTest']
-> cmd is gone. So tearDown *and* cleanUp are both removing the cmd attribute.
before run_test_method: __dict_ _.keys( ) handlers' , '_testMethodName', '_TestCase_ _details' , '_resultForDoCl eanups' , '_unique_id_gen', '_traceback_ id_gens' , '_cleanups', '_type_ equality_ funcs', 'cmd', '_TestCase_ _exception_ handlers' , '_TestCase_ _setup_ called' , '_testMethodDoc', '_TestCase_ _teardown_ called' , '_TestCase_ _RunTest' ]
self.case.
['exception_
after: __dict_ _.keys( ) handlers' , '_testMethodName', '_TestCase_ _details' , '_resultForDoCl eanups' , '_unique_id_gen', '_traceback_ id_gens' , '_cleanups', '_type_ equality_ funcs', 'cmd', '_TestCase_ _exception_ handlers' , '_TestCase_ _setup_ called' , '_testMethodDoc', '_TestCase_ _teardown_ called' , '_TestCase_ _RunTest' ]
(Pdb) self.case.
['exception_
after tearDown:
(Pdb) self.case. __dict_ _.keys( ) handlers' , '_testMethodName', '_TestCase_ _details' , '_resultForDoCl eanups' , '_unique_id_gen', '_traceback_ id_gens' , '_cleanups', '_type_ equality_ funcs', '_TestCase_ _exception_ handlers' , '_TestCase_ _setup_ called' , '_testMethodDoc', '_TestCase_ _teardown_ called' , '_TestCase_ _RunTest' ]
['exception_
-> cmd is gone. So tearDown *and* cleanUp are both removing the cmd attribute.