File tree Expand file tree Collapse file tree 1 file changed +16
-6
lines changed
Expand file tree Collapse file tree 1 file changed +16
-6
lines changed Original file line number Diff line number Diff line change 11#!/usr/bin/env python3
22
3- # Portions of this file contributed by NIST are governed by the following
4- # statement:
3+ # Portions of this file contributed by NIST are governed by the
4+ # following statement:
55#
66# This software was developed at the National Institute of Standards
77# and Technology by employees of the Federal Government in the course
1414#
1515# We would appreciate acknowledgement if the software is used.
1616
17+ import importlib
18+
1719import case_mapping
1820
1921
2022def test_version () -> None :
21- version = case_mapping .__version__
22- assert version is not None
23- assert isinstance (version , str )
23+ """
24+ This test confirms the package version is retrievable and non-null.
25+ """
26+ version_by_init = case_mapping .__version__
27+ assert version_by_init is not None
28+ assert isinstance (version_by_init , str )
2429 # Ensure the version matches the expected major.minor.build format
25- assert len (version .split ("." )) == 3
30+ assert len (version_by_init .split ("." )) == 3
31+
32+ version_by_metadata = importlib .metadata .version ("case_mapping" )
33+ assert version_by_metadata is not None
34+
35+ assert version_by_init == version_by_metadata
You can’t perform that action at this time.
0 commit comments