ipwnponies / pytest-antilru

Bust functools.lru_cache when running pytest to avoid test pollution
MIT License
22 stars 3 forks source link

Add a way to disable this, either per-file or per-test #17

Closed pwmiller closed 4 years ago

pwmiller commented 4 years ago

Doesn't look like there's a way to turn this off temporarily. Not sure if that's necessarily a problem, but it's definitely a nice to have.

ipwnponies commented 4 years ago

@pwmiller what's the use case for wanting to turn this off? I'd be interested in valid use cases, most requests I've heard of are usually solved by using pytest fixtures with higher scope (improve test performance by reintroduce caching). Or a sign that you have test pollution and can stopgap fix it by identifying and extracting the pollution to a fixture, which can be less work than fixing tests sans pollution.

ipwnponies commented 4 years ago

Closing due to inactivity. I've mentioned some solutions that are stopgap workarounds to solving root issue of test pollution.