summaryrefslogtreecommitdiff
path: root/setuptools/tests
diff options
context:
space:
mode:
authorBenoit Pierre <benoit.pierre@gmail.com>2018-08-21 01:54:51 +0200
committerBenoit Pierre <benoit.pierre@gmail.com>2018-08-21 02:01:22 +0200
commit337c008c33ab5799911cc7a8f4e8ff93e715a73b (patch)
tree1f7a25972132ff78456bc3c05a208ff79faa5b7a /setuptools/tests
parentd63b6b5b9fb63c0bfb83fb91edee10114c932e54 (diff)
downloadpython-setuptools-git-337c008c33ab5799911cc7a8f4e8ff93e715a73b.tar.gz
setuptools: fix regression with `egg_info` command
Ensure version is tagged only once.
Diffstat (limited to 'setuptools/tests')
-rw-r--r--setuptools/tests/test_egg_info.py16
1 files changed, 16 insertions, 0 deletions
diff --git a/setuptools/tests/test_egg_info.py b/setuptools/tests/test_egg_info.py
index 1a100266..17d40fb8 100644
--- a/setuptools/tests/test_egg_info.py
+++ b/setuptools/tests/test_egg_info.py
@@ -570,3 +570,19 @@ class TestEggInfo:
raise AssertionError(data)
if output:
assert output in data
+
+ def test_egg_info_tag_only_once(self, tmpdir_cwd, env):
+ self._create_project()
+ build_files({
+ 'setup.cfg': DALS("""
+ [egg_info]
+ tag_build = dev
+ tag_date = 0
+ tag_svn_revision = 0
+ """),
+ })
+ self._run_egg_info_command(tmpdir_cwd, env)
+ egg_info_dir = os.path.join('.', 'foo.egg-info')
+ with open(os.path.join(egg_info_dir, 'PKG-INFO')) as pkginfo_file:
+ pkg_info_lines = pkginfo_file.read().split('\n')
+ assert 'Version: 0.0.0.dev0' in pkg_info_lines