Ozon3Org / Ozon3

An open-source Python package to easily obtain real-time, historical, or forecasted air quality data for anywhere in the world. Reliable, accurate and simple.
GNU General Public License v3.0
66 stars 23 forks source link

Mark slow tests #131

Closed lahdjirayhan closed 2 years ago

lahdjirayhan commented 2 years ago

This PR adds a flag to pytest invocation --skip-slow. This flag allows user to skip tests that takes a long time (mostly get_historical_data stuffs, really). By default, pytest will run all tests, which may or may not be desirable.

pytest --skip-slow

Which tests are slow? I determined it arbitrarily by setting a time limit of how much time it roughly takes over a few test runs. I mark tests that run over 10s in my machine to be "slow".


Note: I haven't documented this anywhere on the repo yet. If this can wait, I'll do some writeups. Otherwise, I can do another PR in the near future.

Milind220 commented 2 years ago

@lahdjirayhan Hey! this appears to have some a conflict, once it's solved I'll merge it in. We can add the documentation for this another time :)