diff options
| author | Jason R. Coombs <jaraco@jaraco.com> | 2015-01-04 12:43:13 -0500 |
|---|---|---|
| committer | Jason R. Coombs <jaraco@jaraco.com> | 2015-01-04 12:43:13 -0500 |
| commit | d8de6c98d879adbe5b8df731a5b61c06a48b9a2f (patch) | |
| tree | 011086c85daacab61b482c72c315222a8245ee78 /pkg_resources | |
| parent | db8efa2a8141205c405cd36f8c8a1aa0b1b7defa (diff) | |
| download | python-setuptools-git-d8de6c98d879adbe5b8df731a5b61c06a48b9a2f.tar.gz | |
Add another assertion on the exception.
Diffstat (limited to 'pkg_resources')
| -rw-r--r-- | pkg_resources/tests/test_resources.py | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/pkg_resources/tests/test_resources.py b/pkg_resources/tests/test_resources.py index fbb9db62..cf16bf03 100644 --- a/pkg_resources/tests/test_resources.py +++ b/pkg_resources/tests/test_resources.py @@ -172,9 +172,12 @@ class TestDistro: # Activation list now includes resolved dependency assert list(ws.resolve(parse_requirements("Foo[bar]"), ad)) ==[Foo,Baz] # Requests for conflicting versions produce VersionConflict - with pytest.raises(VersionConflict): + with pytest.raises(VersionConflict) as vc: ws.resolve(parse_requirements("Foo==1.2\nFoo!=1.2"), ad) + msg = 'Foo 0.9 is installed but Foo==1.2 is required by []' + assert str(vc).endswith(msg) + def testDistroDependsOptions(self): d = self.distRequires(""" Twisted>=1.5 |
