opendbc icon indicating copy to clipboard operation
opendbc copied to clipboard

pytest: slow collection for `car/tests/`

Open adeebshihadeh opened this issue 5 months ago • 0 comments

can/tests/ is 20x faster to collect than car/tests/.

batman:opendbc$ pytest --co can/tests/
============ 22 tests collected in 0.05s ============ 
batman:opendbc$ pytest --co car/tests/
============ 1627 tests collected in 1.04s ============ 

My first suspicion is the use of parameterized. Parameterizing is super important for running all the tests on different car models, so it's worth confirming that it's this and making it faster. Is it faster to just use a for loop?

adeebshihadeh avatar Aug 27 '24 00:08 adeebshihadeh