I have some testcases that involve many fixtures to perform one or two
of the tests.
However, the other 10 tests in that testcase don’t rely on those
fixtures, yet are all the fixtures being loaded in and dropped between
every test method?
If so, how can I avoid this with out bunching up tests into categories
like “these need all these fixtures” and “these dont…”
Don’t write your test such that class X has test XSpec or XTest
instead write tests based on the context of what your testing
ie a Stack element might have 3 test suites
describe EmptyStack do
describe StackWithElements do
describe StackIsFull do
On Apr 5, 11:36 pm, Aryk G. [email protected]
wrote:
I have some testcases that involve many fixtures to perform one or two
of the tests.
However, the other 10 tests in that testcase don’t rely on those
fixtures, yet are all the fixtures being loaded in and dropped between
every test method?
If you are using transactional fixtures (it’s the default), then
fixtures are loaded only once per test run.
Fred