Fix marker parsing

Signed-off-by: Dan Ryan <dan@danryan.co>
This commit is contained in:
Dan Ryan
2018-04-01 12:46:03 -04:00
parent 15c7308ca9
commit d3a08878cf
2 changed files with 5 additions and 2 deletions
+4 -1
View File
@@ -130,7 +130,10 @@ class PipfileRequirement(object):
if _extra_markers:
markers = list(markers) if markers else []
for marker in _extra_markers:
markers.append(_pipfile.pop(marker))
marker = marker.strip()
marker_value = _pipfile.pop(marker).strip()
marker_string = '{0}{1}'.format(marker, marker_value)
markers.append(marker_string)
_pipfile['markers'] = ' and '.join(markers)
return cls(**_pipfile)
+1 -1
View File
@@ -1107,7 +1107,7 @@ requests = "==2.14.0"
# Not sure where travis/appveyor run tests from
test_dir = os.path.dirname(os.path.abspath(__file__))
source_path = os.path.abspath(os.path.join(test_dir, 'test_artifacts', file_name))
with PipenvInstance() as p:
with PipenvInstance(chdir=True) as p:
# This tests for a bug when installing a zipfile in the current dir
copy_to = os.path.join(p.path, file_name)
shutil.copy(source_path, copy_to)