Hello Frank, On Thu, Jun 24, 2010 at 16:35 +0200, Frank Hempel wrote: > Hello, > > I experienced the possibility of funcarg name clashes when defining the > funcarg factories in conftest.py. Lets say there are two project directories > side by side and each has it "own" conftest.py. If both conftest.py's define > a funcarg factory for the the same funcarg-name only the factory of the last > loaded conftest.py is the one used for both directories. > And this holds also when I start the py.test-command from within a project > directory. If i'm in bad luck I get the funcargs from the project' > conftest.py sitting next to me (and there is actually the chance of other > side-effects from the configure/unconfigure methods of the others project > conftest.py). > > I encountered this problem when i integrated third party projects into mine > via svn:externals. > > Maybe i overlooked it, is there the possibility to change the behaviour of > loading the conftest.py's?
Are you using the latest 1.3.1 version? It is meant to call the funcarg factory defined in the closest conftest.py file as seen from the test file. IOW, if you have a/conftest.py b/conftest.py then a/test_1.py and b/test_1.py should use the respective factories in the conftest files. If you experience different behaviour i'd consider it a bug and would kindly ask you to submit a more detailed example. best, holger _______________________________________________ py-dev mailing list py-dev@codespeak.net http://codespeak.net/mailman/listinfo/py-dev