Suppose I have this TestCase class.<br><br>class C(TestCase):<br> def setUp():<br> # very time consuming and resources intensive stuffs.<br> pass<br><br> def test_A(self):<br> pass<br> def test_B(self):<br>
pass<br> def test_C(self):<br> pass<br><br>The unittest docs says:<br><blockquote style="margin: 0pt 0pt 0pt 0.8ex; border-left: 1px solid rgb(204, 204, 204); padding-left: 1ex;" class="gmail_quote">Each instance of the TestCase will only be used to run a single test method, so a new fixture is created for each test.</blockquote>
<div><br>Does this mean that the setUp() method, which is called to prepare the test fixture, get called for test_A, test_B and test_C? In this case is there a way to force just one setUp() call?<br><br>Thanks.<br> </div>