aboutsummaryrefslogtreecommitdiffstats
path: root/setuptools/tests
diff options
context:
space:
mode:
authorJason R. Coombs <jaraco@jaraco.com>2015-11-24 21:21:09 -0500
committerJason R. Coombs <jaraco@jaraco.com>2015-11-24 21:21:09 -0500
commit7bd76e0869310de9da5a32ca2c860f6a1fa461b5 (patch)
treecb43837a41bd718026a00cb0d23a0add53184ff3 /setuptools/tests
parent436be23a0ac5d7f21f261bdcd6fd9119a4f55346 (diff)
downloadexternal_python_setuptools-7bd76e0869310de9da5a32ca2c860f6a1fa461b5.tar.gz
external_python_setuptools-7bd76e0869310de9da5a32ca2c860f6a1fa461b5.tar.bz2
external_python_setuptools-7bd76e0869310de9da5a32ca2c860f6a1fa461b5.zip
Draft a test for testing the new expectation for develop command (and general functionality when console scripts are present).
Diffstat (limited to 'setuptools/tests')
-rw-r--r--setuptools/tests/test_develop.py25
1 files changed, 25 insertions, 0 deletions
diff --git a/setuptools/tests/test_develop.py b/setuptools/tests/test_develop.py
index 725c4ce2..71f0d69a 100644
--- a/setuptools/tests/test_develop.py
+++ b/setuptools/tests/test_develop.py
@@ -85,3 +85,28 @@ class TestDevelop:
expected = 'print("foo")' if PY3 else 'print "foo"'
assert init == expected
+
+ def test_console_scripts(self, tmpdir):
+ """
+ Test that console scripts are installed and that they reference
+ only the project by name and not the current version.
+ """
+ pytest.skip("TODO: needs a fixture to cause 'develop' "
+ "to be invoked without mutating environment.")
+ settings = dict(
+ name='foo',
+ packages=['foo'],
+ version='0.0',
+ entry_points={
+ 'console_scripts': [
+ 'foocmd = foo:foo',
+ ],
+ },
+ )
+ dist = Distribution(settings)
+ dist.script_name = 'setup.py'
+ cmd = develop(dist)
+ cmd.ensure_finalized()
+ cmd.install_dir = tmpdir
+ cmd.run()
+ #assert '0.0' not in foocmd_text