Offline tests
See original GitHub issueHow would this feature be useful? Packaging for distros requires running the tests in a VM isolated from the internet to avoid any pollution. Offline tests are needed for this.
However, the test suite can also be quicker if it uses a fake PyPI server that only contains the packages needed for testing.
Describe the solution you’d like pipenv project tests uses its own, as a fixture in the repo.
There are some other earlier standalone attempts
https://github.com/uranusjr/pytest-pypi-gateway
https://github.com/uranusjr/pytest-fakepi
https://pypi.org/project/pytest-pypi/
https://github.com/manahl/pytest-plugins has a devpi pytest plugin for https://github.com/devpi/devpi
Describe alternatives you’ve considered
An old style PyPI HTML simple
index page.
Issue Analytics
- State:
- Created 4 years ago
- Reactions:1
- Comments:7 (6 by maintainers)
Top GitHub Comments
@jayvdb I’ve done some of this, the easiest is to just setup a devpi instance part of the pytest, as fixture; see https://github.com/tox-dev/integration-test/blob/master/tests/conftest.py#L73-L118
I’m saying to provision the wheels at the first run for the machine if not present already. The other option is to bundle the wheels with the code.