diff options
| author | Jason R. Coombs <jaraco@jaraco.com> | 2016-04-20 09:52:13 -0400 |
|---|---|---|
| committer | Jason R. Coombs <jaraco@jaraco.com> | 2016-04-20 09:52:13 -0400 |
| commit | ae8574c0652f2f25c84521dd26af0688f9882fa2 (patch) | |
| tree | 5645bdcd4cb38354d7592d644b6c93b4bc0c2fa4 /setuptools | |
| parent | 25b2a2d2d586fa80df71e73adb98ab472d97eb10 (diff) | |
| download | python-setuptools-git-ae8574c0652f2f25c84521dd26af0688f9882fa2.tar.gz | |
Add docstrings explaining the intention of the test. Ref #553.
Diffstat (limited to 'setuptools')
| -rw-r--r-- | setuptools/tests/test_egg_info.py | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/setuptools/tests/test_egg_info.py b/setuptools/tests/test_egg_info.py index 7b4f708f..8fbf1323 100644 --- a/setuptools/tests/test_egg_info.py +++ b/setuptools/tests/test_egg_info.py @@ -64,6 +64,12 @@ class TestEggInfo(object): yield env def test_egg_info_save_version_info_setup_empty(self, tmpdir_cwd, env): + """ + When the egg_info section is empty or not present, running + save_version_info should add the settings to the setup.cfg + in a deterministic order, consistent with the ordering found + on Python 2.6 and 2.7 with PYTHONHASHSEED=0. + """ setup_cfg = os.path.join(env.paths['home'], 'setup.cfg') dist = Distribution() ei = egg_info(dist) @@ -92,6 +98,13 @@ class TestEggInfo(object): assert re.search(pattern, content, flags) def test_egg_info_save_version_info_setup_defaults(self, tmpdir_cwd, env): + """ + When running save_version_info on an existing setup.cfg + with the 'default' values present from a previous run, + the file should remain unchanged, except on Python 2.6, + where the order of the keys will be changed to match the + order as found in a dictionary of those keys. + """ setup_cfg = os.path.join(env.paths['home'], 'setup.cfg') build_files({ setup_cfg: DALS(""" |
