summaryrefslogtreecommitdiff
path: root/testing/test_integration.py
diff options
context:
space:
mode:
authorRonny Pfannschmidt <opensource@ronnypfannschmidt.de>2021-09-14 23:03:37 +0200
committerRonny Pfannschmidt <opensource@ronnypfannschmidt.de>2021-09-26 20:05:13 +0200
commit1660900243be8f99cb62c62c0417721a128bdb46 (patch)
tree233e1e6e46012561ed02b1ad658521f9f562f4b5 /testing/test_integration.py
parent0d7d900581a876e038ac3ca452de613d12d1e97a (diff)
downloadsetuptools-scm-1660900243be8f99cb62c62c0417721a128bdb46.tar.gz
add acceptance test for dummy pretend versions
Diffstat (limited to 'testing/test_integration.py')
-rw-r--r--testing/test_integration.py7
1 files changed, 7 insertions, 0 deletions
diff --git a/testing/test_integration.py b/testing/test_integration.py
index c21d8bc..e8854ca 100644
--- a/testing/test_integration.py
+++ b/testing/test_integration.py
@@ -115,6 +115,13 @@ def test_pretend_version_name_takes_precedence(tmpdir, monkeypatch, wd):
assert wd.get_version(dist_name="test") == "1.0.0"
+def test_pretend_version_accepts_bad_string(monkeypatch, wd):
+ monkeypatch.setenv(PRETEND_KEY, "dummy")
+ wd.write("setup.py", SETUP_PY_PLAIN)
+ assert wd.get_version() == "dummy"
+ assert wd("python setup.py --version") == "0.0.0"
+
+
def test_own_setup_fails_on_old_python(monkeypatch):
monkeypatch.setattr("sys.version_info", (3, 5))
monkeypatch.syspath_prepend(os.path.dirname(os.path.dirname(__file__)))