Commit Graph

55 Commits

Author SHA1 Message Date
Oz Tiram be92e26606 testing: disable some CVE checks for new CVEs without fix
This should be revised, but for now we can proceed without it.
2022-11-02 12:26:47 +01:00
Matt Davis 93c8bdaf62 Examine the 20 slowest tests and make improvements. 2022-09-06 00:13:12 -04:00
Matt Davis 9848862927 Convert test runner to use pypiserver package as standalone process (#5284)
* Check point progress on moving tests to pypiserver.

* Allow other indexes to mimic the pypi json API for package hashes.

* Fix these tests that run on lower python versions only.

* Try adding the pypiserver to the github actions to only run once.

* Expand the scope of fixtures for pypiserver.

* try to accomedate microsoft runner.

* Windows networking troubles.

* Remove running as a background job.

* Try to condtionally invoke different start pypi-server commands

* Try to condtionally invoke different start pypi-server commands

* Try to condtionally invoke different start pypi-server commands

* Try to condtionally invoke different start pypi-server commands

* Try to condtionally invoke different start pypi-server commands

* Try to condtionally invoke different start pypi-server commands

* Try to condtionally invoke different start pypi-server commands

* Try to introduce pypi as the root index because setuptools-scm is not in our pypi artifacts.

* see if the windows tests run faster (and the other tests) by supplying waitress.

* Only use waitress on windows because the others are fast on the default.  Fix requests pollution.

* Supply a suitable Pipfile instead for these two failing tests.

* More requests resolver cross test contamination cleanup.

* remove problematic tests because even on my version of python 3.8.12 this does not work due to AttributeError: 'HTMLParser' object has no attribute 'unescape'

* fix mirror install test.

* Fix Pipfile.

* Fix Pipfile for real

* Fix tests

* Cleanup test naming and more test enhancements.

* Save this optimization for a subsequent PR.

* Cleanup the TemporaryDirectory between tests.

* resolve merge conflict.

* Cleanup path initalization -- it hsould always be a TemporaryDirectory for tests that gets cleanedup.

* Cleanup path initalization -- it hsould always be a TemporaryDirectory for tests that gets cleanedup.

* tableflip on those requests tests that read the setup metadata in reqlib from other tests.

* Update developer documentation for running tests.

* add news fragment.

* Try gunicorn perfoormance for linux/mac

* Only use gunicorn on linux based on the results of last run.
2022-09-05 10:19:12 -04:00
Matt Davis 3387881a6d Code reorg utils into utils module reduces complexity (#4990)
* Split apart the massive utils.py into a utils module
2022-03-29 20:27:33 -04:00
Matt Davis 0788b0122e Refactor test into a version that also check quiet mode, move to correct test file.
Add test cases for pip freeze has expected output
Add test for the package index restrictions.
2022-03-26 10:05:56 -04:00
Matt Davis 1207b34e14 Remove broken unused check and broken code argument from pipenv. 2022-03-21 05:52:23 -04:00
Matt Davis e7732e2a1b Add test case for this. 2022-03-11 01:49:16 -05:00
Denis Sazonov f742b9a8ca added a success message for verify 2021-12-20 11:25:46 +00:00
Denis Sazonov 45f8792804 added tests for pipenv verify 2021-12-18 22:29:35 +00:00
Frost Ming e06d9e0287 change a package 2021-11-05 12:43:11 +08:00
Frost Ming 30e2aac739 Fix test error 2021-11-04 18:33:43 +08:00
Ikko Ashimine dd1fdce056 Fix typo in test_cli.py
begining -> beginning
2021-08-17 22:20:18 +09:00
Frost Ming 904f0a3b86 capture outputs written in subprocesses 2021-08-03 10:41:19 +08:00
Frost Ming 6ef9344a5f Avoid wait() on processes 2021-07-29 14:42:52 +08:00
Frost Ming 9b4eb98529 Remove unused patch files 2021-07-28 17:30:17 +08:00
Frost Ming a82bbb7b27 Try switching from delegator to subprocess 2021-07-28 16:39:36 +08:00
Frost Ming ca5d931f1f Update to py36 plus syntax 2021-07-28 10:59:00 +08:00
Glen Smith 243e300517 add inspection for 'which python' 2020-09-03 09:04:46 -06:00
Glen Smith c42f6094e9 Change the script command to scripts 2020-09-02 10:35:20 -06:00
Glen Smith 0e90c37d9f Merge remote-tracking branch 'upstream/master' into master 2020-09-02 10:18:55 -06:00
frostming 8c959096a8 Adapt test cases to prefer the mocked PyPI. 2020-09-01 16:35:37 +08:00
Glen Smith 622d119ea6 Fix script command and testing:
- Use string format compatible with python 2.7
- Use `click.echo`, not `print`
- The command is `pipenv script` not `pipenv scripts`
- The stanza label in Pipfile is `[scripts]`, not `[script]`
- The default when getting from the pipfile should be dict, not a list
2020-08-28 15:14:35 -06:00
Glen Smith 4e3baf5713 Fix command as script, not scripts 2020-08-28 12:15:52 -06:00
Glen Smith 07d166ac3b Add a scripts command and a test for it.
- https://github.com/pypa/pipenv/issues/3686
2020-08-28 12:08:58 -06:00
frostming 7d36f3fbda Reformat codes 2019-09-06 18:06:05 +08:00
Frost Ming 2dc8d0a070 use another version 2019-08-03 16:54:44 +08:00
Frost Ming c3b4c410fa change the version specifier 2019-08-03 11:42:07 +08:00
Frost Ming 7708cd8445 Pass lock options to outdated 2019-08-03 10:44:45 +08:00
John Vandenberg 050d9b4c78 graph tests: Replace requests with tablib 0.13.0
These tests fail when using requests in a de-vendored installation
because requests is part of the pre-installed image.

tablib has fewer constraints on its dependencies, however its
dependency tree is complicated enough to approximately test
the same functionality, and allows the graph tests to pass
even when de-vendored.
2019-07-11 13:33:01 +07:00
Dan Ryan 5ac676711a Fix editable VCS dependency resolution
- Fixes #3809

Signed-off-by: Dan Ryan <dan@danryan.co>
2019-07-05 02:06:43 -04:00
Dan Ryan 83868c8f1a Cut over to devpi for tests and improve logging
- Verbose logs will now write gracefully to the terminal even while the
  spinner is running (i.e. during locking)
- This PR also cuts over to Devpi for a backing cache rather than a
  hacked httpbin instance
- Inclues a refactor of `pip_install` to deduplicate logic
- Attempts to switch back to relying on native editable installs in pip
  as the current implementation is broken on master (i.e. nothing is
  installed in the virtualenv)
- Fixes #3809

Signed-off-by: Dan Ryan <dan@danryan.co>
2019-06-25 01:26:49 -04:00
Dan Ryan 2a0cc13f4e Merge branch 'master' into fix-several-general-options 2019-06-04 21:37:00 -04:00
Dan Ryan 359906c669 Update tests to resolve some transient resolution issues
Signed-off-by: Dan Ryan <dan@danryan.co>

probably need to sync submodules for this to work

Signed-off-by: Dan Ryan <dan@danryan.co>

Update to new version of artifacts

Signed-off-by: Dan Ryan <dan@danryan.co>

Fix windows failure

Signed-off-by: Dan Ryan <dan@danryan.co>

Update azure-pipelines.yml for Azure Pipelines

Update lockfile test for windows

Signed-off-by: Dan Ryan <dan@danryan.co>

Fix scandir test

Signed-off-by: Dan Ryan <dan@danryan.co>

Update azure test steps

Signed-off-by: Dan Ryan <dan@danryan.co>

Fix virtualenv test

Signed-off-by: Dan Ryan <dan@danryan.co>

Fix python discovery when nothing is supplied

Signed-off-by: Dan Ryan <dan@danryan.co>

Fix cli ensure_project call

Signed-off-by: Dan Ryan <dan@danryan.co>

Fix run in virtualenv test

Signed-off-by: Dan Ryan <dan@danryan.co>

Show why virtualenv test failed if it did

Signed-off-by: Dan Ryan <dan@danryan.co>

Fix python interpreter discovery

Signed-off-by: Dan Ryan <dan@danryan.co>

scale down lock test modifications and increase error logging

Signed-off-by: Dan Ryan <dan@danryan.co>

Fix spinner bugs on windows and python discovery

Signed-off-by: Dan Ryan <dan@danryan.co>

Fix pythonfinder search algorithm to dodge false paths on win

Signed-off-by: Dan Ryan <dan@danryan.co>

use pipenv directly

Signed-off-by: Dan Ryan <dan@danryan.co>
2019-06-03 22:01:07 -04:00
jxltom 7f2eaf7d50 Fix tests 2019-05-28 10:34:09 +08:00
Dan Ryan 57cba47669 Merge branch 'master' into fix-several-general-options 2019-05-27 19:08:20 -04:00
frostming bc37beaef4 cleanup 2019-05-20 16:42:18 +08:00
frostming 457a42a69c exclude venv folders 2019-05-20 16:04:58 +08:00
frostming e6b2f6463a add news entry 2019-05-20 12:45:09 +08:00
Dan Ryan d8dbb8314f Merge branch 'master' into fix-several-general-options 2019-05-19 22:01:20 -04:00
Dan Ryan a1973f42ff Merge branch 'master' into bugfix/check_unused 2019-05-19 22:00:56 -04:00
Dan Ryan d8e66c7fce Add future imports to tests
Signed-off-by: Dan Ryan <dan@danryan.co>
2019-05-16 00:52:10 -04:00
frostming 1384a25a38 make check unused work 2019-05-14 09:54:18 +08:00
Unknown 88e30d8fd2 Add smoke test for --three argument 2019-05-07 10:48:22 +08:00
jxltom dfec732860 Add test for pipenv --clear 2019-05-07 09:19:25 +08:00
nonylene f81e86181c Add test for pipenv --python --site-packages 2018-12-09 05:17:25 +09:00
jxltom 85e64b86be Resort imports for tests 2018-12-01 17:26:32 +08:00
Dan Ryan 9bdbe3464d syntax error...
Signed-off-by: Dan Ryan <dan@danryan.co>
2018-10-13 04:42:32 -04:00
Dan Ryan 329183019a fix installation of non-editable requirements
- Fix tests to ensure commands return prior to follow ups

Signed-off-by: Dan Ryan <dan@danryan.co>
2018-10-13 04:27:21 -04:00
Dan Ryan b408fd3dd3 Fix pipenv clean tests
Signed-off-by: Dan Ryan <dan@danryan.co>
2018-10-10 10:18:57 -04:00
Erin O'Connell 48970d901d new test for pipenv --support 2018-06-29 11:33:37 -06:00