File tree Expand file tree Collapse file tree 1 file changed +16
-1
lines changed Expand file tree Collapse file tree 1 file changed +16
-1
lines changed Original file line number Diff line number Diff line change 33
44import nibabel as nib
55from nibabel .pkg_info import cmp_pkg_version
6+ from ..info import VERSION
67
78from nose .tools import (assert_raises , assert_equal )
89
910
1011def test_pkg_info ():
11- """Simple smoke test
12+ """Smoke test nibabel.get_info()
1213
1314 Hits:
1415 - nibabel.get_info
@@ -23,6 +24,20 @@ def test_version():
2324 assert_equal (nib .pkg_info .__version__ , nib .__version__ )
2425
2526
27+ def test_fallback_version ():
28+ """Test fallback version is up-to-date
29+
30+ This should only fail if we fail to bump nibabel.info.VERSION immediately
31+ after release
32+ """
33+ assert (
34+ # dev version should be larger than tag+commit-githash
35+ cmp_pkg_version (VERSION ) >= 0 or
36+ # Allow VERSION bump to lag releases by one commit
37+ VERSION == nib .__version__ + 'dev' ), \
38+ "nibabel.info.VERSION does not match current tag information"
39+
40+
2641def test_cmp_pkg_version ():
2742 # Test version comparator
2843 assert_equal (cmp_pkg_version (nib .__version__ ), 0 )
You can’t perform that action at this time.
0 commit comments