summaryrefslogtreecommitdiff
path: root/pkg_resources/tests/test_resources.py
diff options
context:
space:
mode:
authorJason R. Coombs <jaraco@jaraco.com>2016-04-07 21:16:56 +0100
committerJason R. Coombs <jaraco@jaraco.com>2016-04-07 21:16:56 +0100
commit1bf18cc8573bf0faea6d5a7cd123f41e49287210 (patch)
tree6ddd4fef25bc2f5704bf8ad840b8d8297b53ede3 /pkg_resources/tests/test_resources.py
parenta31716f5a86061d7409b8c08154d3b52ff324efd (diff)
parent3d8c2245cb09e0db917648f2cf57f99fd10caca1 (diff)
downloadpython-setuptools-git-1bf18cc8573bf0faea6d5a7cd123f41e49287210.tar.gz
Merge pull request #532 from s-t-e-v-e-n-k/readd-exception-for-marker-eval
Reinstate the or guard in WorkingSet._markers_pass
Diffstat (limited to 'pkg_resources/tests/test_resources.py')
-rw-r--r--pkg_resources/tests/test_resources.py6
1 files changed, 6 insertions, 0 deletions
diff --git a/pkg_resources/tests/test_resources.py b/pkg_resources/tests/test_resources.py
index 7f86c797..7907224e 100644
--- a/pkg_resources/tests/test_resources.py
+++ b/pkg_resources/tests/test_resources.py
@@ -186,6 +186,12 @@ class TestDistro:
res = ws.resolve(parse_requirements("Foo;python_version>='2'"), ad)
assert list(res) == [Foo]
+ def test_environment_marker_evaluation_called(self):
+ ws = WorkingSet([])
+ req, = parse_requirements("bar;python_version<'4'")
+ extra_req_mapping = {req: ()}
+ assert ws._markers_pass(req, extra_req_mapping) == True
+
def test_marker_evaluation_with_extras(self):
"""Extras are also evaluated as markers at resolution time."""
ad = pkg_resources.Environment([])