Closed CleanCut closed 9 years ago
Hey, thanks for addressing this.
It's also worth noting that if this were documented, I'd have just added the __init__.py
and not thought twice about it, so that's possibly a perfectly suitable stopgap until a better solution is found.
Thanks again!
No problem! I have found that the biggest obstacle to fixing bugs is simply becoming aware that the bug even exists. Thanks for clueing me in!
@mekhami Okay, I'm baffled. I cannot reproduce the problem myself. Is there any way that you could provide me with a minimal project that has the problem? Everything I have tried has ended up actually being loaded and run successfully, whether or not there was an __init__.py
present.
Okay, I can't reproduce the problem, so I'm going to close this issue. If someone can provide me with a way to actually reproduce the problem reliably, we'll reopen this issue and get it fixed.
@CleanCut, are you looking for a project that green
won't run if there is a missing __init__.py
?
@MinchinWeb Specifically, a project where tests/
is a sibling directory to the project code, and there is no tests/__init__.py
and green won't run the tests.
@CleanCut, I think that was the issue with #74 : tests/
was a folder at the same level as the main module, and with no tests/__init__.py
, green won't run the tests, but oddly only on Windows. See if colourettu will work as the test case you're looking for.
It is very common to have:
The main process discovers the tests fine, but when the worker receives the name of the module, it fails to load it when
tests/
doesn't have an__init__.py
.Fixing this may also fix other run-green-from-a-different-directory-can't-load-tests problems.