Skip to content

Commit c90b897

Browse files
committed
Use version.py file in __init__.py to be more DRY
1 parent 07ef286 commit c90b897

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

pytest_httpbin/__init__.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,8 @@
11
import pytest
22

3-
__version__ = '0.0.3'
3+
with open("pytest_httpbin/version.py") as f:
4+
code = compile(f.read(), "pytest_httpbin/version.py", 'exec')
5+
exec(code)
46

57
use_class_based_httpbin = pytest.mark.usefixtures("class_based_httpbin")
68
use_class_based_httpbin_secure = pytest.mark.usefixtures("class_based_httpbin_secure")

0 commit comments

Comments
 (0)