Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

make -jN work properly #28

Closed
mgedmin opened this issue May 19, 2015 · 2 comments
Closed

make -jN work properly #28

mgedmin opened this issue May 19, 2015 · 2 comments

Comments

@mgedmin
Copy link
Member

mgedmin commented May 19, 2015

Currently zope-testrunner -jN runs the first test layer serially, and only then starts forking N subprocesses for parallel execution. People have been creating workarounds for this by adding an empty test layer named something like .!no tests here! to get the 1st serial layer out of the way ASAP, so the rest of the tests can run in parallel.

The change in 4.4.5 (run the unit test layer first, https://bugs.launchpad.net/zope.testrunner/+bug/497871) broke this hack.

Suggestion: if the test runner sees -j on the command line, let it create an empty test layer automatically and insert it in front of all other layers. (Maybe make it conditional on there being at least two other layers, maybe don't bother -- who would use -j when there's only one test layer?)

@mgedmin
Copy link
Member Author

mgedmin commented May 19, 2015

BTW fixing this will make the regression test for #6 invalid. The test should probably be rewritten to avoid -j and instead explicitly define a test layer that does os.chdir() and raises NotImplementedError from layer teardown.

@mgedmin
Copy link
Member Author

mgedmin commented May 21, 2015

Released in 4.4.9.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant