I am trying to write unittests in python 2.3. I’ve got everything working accept the class level setUp and tearDown function. I’ve tried to look online but am not able to find a way to define these in a python 2.3 unittest case.
Hence, is it possible to have setUpClass() & tearDownClass() in a python 2.3 testcase? If yes, how do I go about doing that?
Try to use nose or other runner that is compatible with python 2.3; The python 2.3 runner didn’t know about this methods (setUpClass/tearDownClass).
In python 2.3 to decorate a function you should do manually (no syntactic sugar) like: