Hi! j. vickroy wrote: [snip] > The attached file (py-test-generator-trial.py) demonstrates a behavior I > do not understand. [snip]
I don't know generative test semantics all that well, I hoped somebody else would answer this. However, my theory is as follows: py.test first collects all the results of the generator and then runs them all. Since your test keeps global state, the state is already changed when the first test is run. To me this sounds like reasonable behavior, global state is not good in tests anyway. Does that make things clearer? Cheers, Carl Friedrich _______________________________________________ py-dev mailing list py-dev@codespeak.net http://codespeak.net/mailman/listinfo/py-dev