A
A
Anton2018-09-16 14:36:02
Python
Anton, 2018-09-16 14:36:02

How to call setUp and tearDown while executing the same test?

Hello. I have a certain class with test methods, and the setUp and tearDown methods are overridden in it, which perform the actions I need before and after the test is executed, but the trouble is that if you run one test method, then the setUp and tearDown methods will not be called, tell me is there a way to do this?
I use unittest for testing.

Answer the question

In order to leave comments, you need to log in

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question