Closed gricey432 closed 2 months ago
I've confirmed it's definitely an interaction with freezegun. Adding the following to conftest resolved it.
import freezegun
freezegun.configure(extend_ignore_list=['buildkite_test_collector'])
Thanks for raising this, don't think we can reasonably support such behaviour automatically for all time mocking tools.
Going to close this issue based on the fact that the ignore list fix works around it.
See https://github.com/spulec/freezegun?tab=readme-ov-file#ignore-packages for more details.
Just tried this out for the first time and the reported runtimes for my suite as well as some of the tests are wildly wrong.
The suite ran in about 15 minutes.
The tests which have the huge runtimes are all using Freezegun to mess with the clock https://github.com/spulec/freezegun which feels like it's probably related.
Freezegun has its own ignore system, unsure if that's the best fix for this or if the test collector should automatically handle libraries like this.