Bug#1024971: pybuild: should fail when the result of running tests is "Ran 0 tests in 0.000s"
Hi Louis-Philippe (2022.11.28_14:44:36_-0400) > I don't think unittest provides an interface to achieve this. Now implemented! https://github.com/python/cpython/pull/102051 This will cause all the packages that don't have tests to fail their empty test suite. We'll have to decide what to do about that... Stefano -- Stefano Rivera http://tumbleweed.org.za/ +1 415 683 3272
Bug#1024971: pybuild: should fail when the result of running tests is "Ran 0 tests in 0.000s"
Hi Louis-Philippe (2022.11.27_23:46:58_+) > When this happens, the result of the test command typically looks like "Ran > 0 tests in 0.000s". I don't think unittest provides an interface to achieve this. We're probably stuck parsing logs if we want it. Pytest makes it easy: https://github.com/pytest-dev/pytest/pull/817 SR -- Stefano Rivera http://tumbleweed.org.za/ +1 415 683 3272
Bug#1024971: pybuild: should fail when the result of running tests is "Ran 0 tests in 0.000s"
Package: dh-python Version: 5.20221122 Severity: wishlist Dear maintainers, Too often, a mistake or a misconfiguration leads to no tests being detected when trying to run the upstream testsuite. When this happens, the result of the test command typically looks like "Ran 0 tests in 0.000s". I thought we could catch this via Lintian and warn people, but I just realised Lintian does not have access to the build log. This means if we want people to be aware of what, in my opinion, is a build failure, it should be done via pybuild. As such, it would be nice if pybuild considered this case as a failure and exited if it happens. We probably will need to do a MBF beforehand though, as I'm sure it happens in tons of packages. If there are no tests for real, I think it's OK to ask people to disable them altogether :) Cheers, -- ⢀⣴⠾⠻⢶⣦⠀ ⣾⠁⢠⠒⠀⣿⡁ Louis-Philippe Véronneau ⢿⡄⠘⠷⠚⠋ po...@debian.org / veronneau.org ⠈⠳⣄ OpenPGP_0xE1E5457C8BAD4113.asc Description: OpenPGP public key OpenPGP_signature Description: OpenPGP digital signature