jiridanek opened a new pull request, #18:
URL: https://github.com/apache/qpid-python/pull/18
The problem stems from the way the testcode imports the production code, so
that when both have a module of the same name, the test runner descends into
the production code when discovering tests, instead of into the test code.
```
{code:title=qpid/tests/messaging/__init__.py}
from qpid.tests.messaging.implementation import *
[...]
from . import address, endpoints, message, selector
{code}
The file imported on the first line contains
{code:title=qpid/tests/messaging/implementation.py}
from qpid.messaging import *
{code}
```
and {{qpid.messaging}} contains its own {{address.py}} submodule.
Therefore, when {{qpid-test-runner}} tries to access
{{qpid.tests.messaging.mesage}}, it actually gets {{qpid.messaging.message}},
which was imported first. But that does not contain any tests, and the message
tests are missed and never executed.
This only started happening after my relative imports modernizing commit
https://github.com/apache/qpid-python/commit/9651001c6fe0b65e538a96e27df36582b7ccb004.
Before, Totals: 349 tests, 349 passed, 0 skipped, 0 ignored, 0 failed and
Totals: 678 tests, 585 passed, 93 skipped, 0 ignored, 0 failed
(https://github.com/apache/qpid-python/actions/runs/4661323947/jobs/8250463871)
After, Totals: 218 tests, 218 passed, 0 skipped, 0 ignored, 0 failed and
Totals: 547 tests, 454 passed, 93 skipped, 0 ignored, 0 failed
(https://github.com/apache/qpid-python/actions/runs/4661535006/jobs/8250915935)
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]