Closed bmorris3 closed 4 years ago
By default you can pass extra arguments to pytest by doing tox -e ... -- --remote-data
.
If you want to have a specific environment which runs the online tests (i.e. tox -e
py38-online) you can customise the
commands=` line in tox.ini, you can look at sunpy's tox.ini file to see an example of doing this.
Also see the core package's Travis configuration to see how to add the flag during CI to only some builds.
@Cadair – Ah thanks! When I tried tox -e test --remote-data
I get:
tox -e test --remote-data
tox: error: unrecognized arguments: --remote-data
I see that I needed the extra --
to make it work.
Thanks also to @astrofrog for the syntax example!
Hi team!
I'm working with the package template on a package that has fetches some remote data within its tests. I think the way to flag this in the tox infrastructure is to add the flag:
Is that correct, or is there a better way to do it? Perhaps we can add this line to the package template and comment it out, so it's easy to discover for other users?