Commit Graph

700 Commits

Author SHA1 Message Date
Dan Ryan 06f3cae5e2 Merge branch 'master' into fix-queue 2019-06-04 03:23:27 -04:00
Dan Ryan b5643760e3 Fix test comparisons
Signed-off-by: Dan Ryan <dan@danryan.co>
2019-06-04 02:08:05 -04:00
Dan Ryan 1525f88676 Don't use tablib for keep_outdated test due to osx failure
Signed-off-by: Dan Ryan <dan@danryan.co>
2019-06-04 01:39:03 -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
Dan Ryan 401c7c1746 Move test artifacts to submodule
Signed-off-by: Dan Ryan <dan@danryan.co>
2019-06-03 22:00:18 -04:00
Gleb Kozyrev 403a65105c Test sync --sequential processing every pip install result 2019-05-27 19:42:18 -04:00
Dan Ryan f0e3bbaa79 parent 8ae44bc90b
author Dan Ryan <dan@danryan.co> 1554074378 -0400
committer Dan Ryan <dan@danryan.co> 1558982736 -0400
gpgsig -----BEGIN PGP SIGNATURE-----

 iQIzBAABCgAdFiEEb6jpcpb+5zzDideCsyDQTvvOpJUFAlzsMFAACgkQsyDQTvvO
 pJWZmRAAtge5wdprlLnKdWUYK5USZb7Uk3zJHi9UIvnO7nKP6UA/L2D/5nxZitvx
 pZI7cGG+8sLp2yZNtQZdW6LNM1jmRXgzdMLYQh/5zo5gbj6KLOw7erh0FU3L3uM6
 wNBNM135Eqt7b+4a4C5TEK2UjwRxBHAsF+3ZzUy+UJQqgQEKxFVxW4gC4yxpfMtL
 jipE8ludwuOIM88ZJapmLpv2R6adQTxWZedTlmczdsy2/WKGHTCCpWs96PBbntdI
 pVBmoXfMhgZi+IuGR3iBYU0qS97vjJ8Te9tQZAaB9JGSqv3hHDWo1ht/rrG2RXzp
 3i0Cf2vG4035EUh56VYE9FCC9m6Vu3U9iIR34BZG9K5+lDP7pmJmjT+GymEgMP0N
 GoP3LYUO+dJjMjaUEMsC6QIi6DAots3uk4lxIw3wcA4Im/N/i5xafsRj1Eu3UdBL
 wBDKMz/FQjH+tD+mnvTlzaxD5vdhhCdBu1gK59rjNMlzg8hz6EF61QbHCaQHd4UI
 VOGIa8ThLlLI3addxzq/McceAc+OsLJ9hm06jkjvvoIuKrHyE3DybdbYQC7uEwyw
 2AvVuMDCPcciYQnkJhNTKmGvPcUDYD7cF91GKcUJKdPdyzDCeFEo5SUTKnLV4Cj2
 VD2sdVUk4jnmYfE4pCFvHKYooxQDMKQk/VCKl1c9QHL9/ijCx+o=
 =b+H1
 -----END PGP SIGNATURE-----

Ensure resolver doesn't compare editable specifiers

- Don't compare versions of editable dependencies when updating using
  `--keep-outdated` -- editable dependencies will now be updated to
  the latest version
- Ensure we don't drop markers from the lockfile when versions are not
  updated
- Fixes #3656
- Fixes #3659

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

Add future import for print function

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

Handle all possible markers in lockfiles

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

Fix json import

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

point to correct reference for lockfile

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

Fix marker merging errors

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

Prevent automatically setting `editable=True`

- Fixes #3647

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

Add new feature toggle for VCS dependency resolution

- Fixes #3577

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

Fix syntax error

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

Use string for environment

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

Fix class name resolution for py27

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

Write json files as unicode

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

Fix resolution with env var

Signed-off-by: Dan Ryan <dan@danryan.co>
2019-05-27 17:44:41 -04:00
Dan Ryan d1c086afbb Merge branch 'master' into master 2019-05-26 17:22:04 -04:00
Dan Ryan 7d0b0f6632 Merge branch 'master' into conftest-checks-ignore-KeyboardInterrupt 2019-05-26 17:05:53 -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 a1973f42ff Merge branch 'master' into bugfix/check_unused 2019-05-19 22:00:56 -04:00
Dan Ryan c23e57b482 Fix test and pipeline definitions
- Update extras name in pipelines
- fix windows virtualenv calls
- don't write debug info during virtualenv creation and just move on
- Generalize some pipelines
- Use quotes around evaluated statements in pipeline
- Fix envvar references
- Update vistir:
  - fix stream wrapper on windows
  - fix ICACLS permissions handler
  - fix path normalization function
- Update azure venv creation script
- Fix vendoring script

Signed-off-by: Dan Ryan <dan@danryan.co>
2019-05-18 23:22:53 -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
Dan Ryan 210495992b Fix marker formatting in keep outdated test
Signed-off-by: Dan Ryan <dan@danryan.co>
2019-05-15 21:36:06 -04:00
Dan Ryan 102b682284 Fix keep_outdated markers
Signed-off-by: Dan Ryan <dan@danryan.co>
2019-05-15 21:27:51 -04:00
Dan Ryan b7de7c1cdf Fix marker formatting and inclusion
Signed-off-by: Dan Ryan <dan@danryan.co>
2019-05-15 20:43:31 -04:00
Dan Ryan e3bf42e57e Merge remote-tracking branch 'origin/master' into update-vendored-deps 2019-05-15 20:39:44 -04:00
frostming 1384a25a38 make check unused work 2019-05-14 09:54:18 +08:00
Miro Hrončok 6152199752 Pytest 4: Update to get_closest_marker
See https://docs.pytest.org/en/latest/mark.html#update-marker-code
2019-05-03 12:23:33 +02:00
Dan Ryan ff4c8b0d5c Update vendored deps
Signed-off-by: Dan Ryan <dan@danryan.co>
2019-04-18 13:50:48 -04:00
John Vandenberg 8e584055cf conftest.py: Ignore KeyboardInterrupt
During check_internet() and check_github_ssh(), a KeyboardInterrupt
should be interpreted as user desire to escape the check, not escape
the entire test run.  This is especially true during check_github_ssh
which may require a passphrase from the user, which they might feel
uncomfortable giving during a test suite.

After these checks are bypassed, there is user feedback indicating the
tests are running, and so they can trigger KeyboardInterrupt again if
they wish to escape the entire test run.
2019-04-03 10:19:00 +07:00
Dan Ryan 6af815fb92 Merge branch 'master' into test_specific_package_environment_markers 2019-03-29 20:50:02 -04:00
Dan Ryan c7b2a522ce Merge branch 'master' into feature/keep-outdated-peep 2019-03-25 01:05:45 -04:00
John Vandenberg 1d87a6aff7 Avoid using requests in tests
test_specific_package_environment_markers using requests
fails when requests is pre-installed via PYTHONPATH.

Closes https://github.com/pypa/pipenv/issues/3644
2019-03-25 03:11:48 +07:00
Dan Ryan 92010826c8 Erm, remove verbose mode from tests
Signed-off-by: Dan Ryan <dan.ryan@xyleminc.com>
2019-03-24 15:58:10 -04:00
Dan Ryan 32e918fd46 Don't print extra strings to stdout
Signed-off-by: Dan Ryan <dan.ryan@xyleminc.com>
2019-03-24 14:49:15 -04:00
Dan Ryan 6971468f02 Write resolution results to temp json file instead of stdout
Signed-off-by: Dan Ryan <dan.ryan@xyleminc.com>
2019-03-24 13:10:17 -04:00
Dan Ryan a960990103 fix double declaration of kwarg
Signed-off-by: Dan Ryan <dan.ryan@xyleminc.com>
2019-03-23 22:36:03 -04:00
Dan Ryan 4a0b2b759a monkeypatch shutil.rmtree for tests
Signed-off-by: Dan Ryan <dan.ryan@xyleminc.com>
2019-03-23 21:59:44 -04:00
Dan Ryan 7d8f517229 Try ditching pip_src_dir in tests
Signed-off-by: Dan Ryan <dan@danryan.co>
2019-03-21 22:05:32 -04:00
Dan Ryan e16608c03f sort pytest markers by length
Signed-off-by: Dan Ryan <dan@danryan.co>
2019-03-18 00:45:40 -04:00
Dan Ryan 6382f516e2 Merge branch 'master' into feature/keep-outdated-peep
Signed-off-by: Dan Ryan <dan@danryan.co>
2019-03-18 00:43:40 -04:00
Dan Ryan 116d0857a2 Fix variable references
Signed-off-by: Dan Ryan <dan@danryan.co>

Fix variable references

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

Fix variable references

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

Switch to powershell for windows virtualenv creation

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

use python version as path

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

use python version as path

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

swap variable name for python exe

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

add fallback for python exe

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

fix python variable setting

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

fix python variable setting

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

Use variable susbstitution for python executable location

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

Use activate script properly

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

Fix floating quote in python version

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

Don't block on safety call in python 2 as it overwrites output for some reason

Signed-off-by: Dan Ryan <dan.ryan@xyleminc.com>

Don't block on pipenv graph either

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

Check command return code instead of calling `block`

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

Don't load json after its already loaded

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

Wait on return code before checking contents

Signed-off-by: Dan Ryan <dan@danryan.co>
2019-03-16 15:11:05 -04:00
Dan Ryan 466fcc0a2a Fix test skip
Signed-off-by: Dan Ryan <dan@danryan.co>
2019-03-16 15:10:51 -04:00
Dan Ryan 73129d8401 Fix internet connectivity test
Signed-off-by: Dan Ryan <dan@danryan.co>
2019-03-16 15:10:50 -04:00
Dan Ryan 8fdc589d05 Fix test skip
Signed-off-by: Dan Ryan <dan@danryan.co>
2019-03-16 15:10:50 -04:00
Dan Ryan dcfce70817 Fix python path discovery if not called python
- Begin a refactor of `delegator.run` invocation to ensure we capture
  and handle failures with our own exception wrappers
- Additoinally capture output and error logging and command information
  when running in verbose mode (should avoid significant repitition in
  the codebase)
- Refactor `which` and `system_which` to fallback to pythonfinder's
implementation
- Abstract `is_python_command` to identify whether we are looking for
  python, this enables us to rely on `pythonfinder.Finder.find_all_python_versions()`
  to ensure we aren't skipping python versions
- Fixes #2783

Signed-off-by: Dan Ryan <dan@danryan.co>
2019-03-16 15:10:40 -04:00
Dan Ryan 0382e0c9cc Merge branch 'master' into feature/keep-outdated-peep 2019-03-10 04:28:04 -04:00
Dan Ryan 6552e8dc8b Add tests for --keep-outdated
- Test that the lockfile doesn't get updated if satisfying constraints
  are pinned already in the lockfile
- Test that pipfile pins are respected
- Test that dependencies in the lockfile with markers that don't apply
  to the current system stay in the lockfile

Signed-off-by: Dan Ryan <dan@danryan.co>
2019-03-10 04:18:10 -04:00
Frost Ming bf2df74d72 Merge branch 'master' into bugfix/3502-trusted-host-custom-port 2019-03-07 09:07:15 +08:00
Dan Ryan 62a45e3323 Merge branch 'master' into bugfix/3502-trusted-host-custom-port 2019-03-06 19:09:01 -05:00
Dan Ryan 545ce5e7b5 Merge branch 'master' into i3292 2019-03-06 19:00:29 -05:00
Dan Ryan 912cce2edd Merge branch 'master' into master 2019-03-06 19:00:10 -05:00
Miro Hrončok ac44a238fb Update pytest-pypi documentation not to be pytest-httpbin documentation
Fixes https://github.com/pypa/pipenv/issues/3292
2019-02-26 11:34:51 +01:00
Dan Ryan b0ba9a8766 Update syntax for context manager virtualenv test class
Signed-off-by: Dan Ryan <dan@danryan.co>
2019-02-23 14:23:18 -05:00
Dan Ryan 090619a6a1 Fix virtualenv tempdir lifespan
Signed-off-by: Dan Ryan <dan@danryan.co>
2019-02-23 13:11:32 -05:00
Lee Bontecou c05066cfe3 add unittests 2019-02-22 12:21:27 -06:00
Dan Ryan 3bc48f034f Fix venv with leading dash test on windows and clean up tests
Signed-off-by: Dan Ryan <dan@danryan.co>
2019-02-21 22:18:00 -05:00