We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 4143ec0 commit b6a3485Copy full SHA for b6a3485
1 file changed
tests/test_binding.py
@@ -7,6 +7,7 @@
7
8
import correctionlib
9
import correctionlib.schemav2 as cs
10
+import correctionlib.version
11
12
13
@pytest.fixture(scope="module")
@@ -90,7 +91,8 @@ def test_cmake_static_compilation(csetstr: str):
90
91
f.write(CMAKELIST_SRC)
92
testprog = os.path.join(tmpdir, "test.cc")
93
# SKBUILD_PROJECT_VERSION only includes major.minor.patch
- versionstr = ".".join(correctionlib.__version__.split(".")[:3])
94
+ # it also trims any prerelease suffixes
95
+ versionstr = ".".join(map(str, correctionlib.version.__version_tuple__[:3]))
96
with open(testprog, "w") as f:
97
f.write(TESTPROG_SRC % (versionstr, csetstr))
98
flags = (
0 commit comments