File tree Expand file tree Collapse file tree 3 files changed +24
-2
lines changed Expand file tree Collapse file tree 3 files changed +24
-2
lines changed Original file line number Diff line number Diff line change 1212SetDefaultPickleProperties (PropertyPickleOptions .AllProps )
1313
1414__all__ = [
15+ "__version__" ,
1516 "Pipeline" ,
1617 "ErrorFilter" ,
1718 "FilterReinserter" ,
1819 "PostPredictionWrapper" ,
1920]
21+
22+ __version__ = "0.9.2"
Original file line number Diff line number Diff line change @@ -3,19 +3,19 @@ requires = ["setuptools"]
33build-backend = " setuptools.build_meta"
44
55[project ]
6- dynamic = [" dependencies" , " optional-dependencies" ]
6+ dynamic = [" dependencies" , " optional-dependencies" , " version " ]
77name = " molpipeline"
88authors = [
99 {name = " Christian W. Feldmann" },
1010 {name = " Jennifer Hemmerich" },
1111 {name = " Jochen Sieg" }
1212]
1313description = " Integration of rdkit functionality into sklearn pipelines."
14- version = " 0.9.2"
1514readme = " README.md"
1615
1716[tool .setuptools .dynamic ]
1817dependencies = {file = " requirements.txt" }
18+ version = {attr = " molpipeline.__version__" }
1919
2020[tool .setuptools .dynamic .optional-dependencies ]
2121all = {file = [" requirements_chemprop.txt" , " requirements_notebooks.txt" ]}
Original file line number Diff line number Diff line change 1+ """Test functionality set at package init."""
2+
3+ import unittest
4+
5+ from molpipeline import __version__
6+
7+
8+ class TestInit (unittest .TestCase ):
9+ """Test functionality set at package init."""
10+
11+ def test_version (self ) -> None :
12+ """Test that the package has a version."""
13+ self .assertIsInstance (__version__ , str )
14+ splitted = __version__ .split ("." )
15+ self .assertEqual (len (splitted ), 3 )
16+ major , minor , patch = splitted
17+ self .assertTrue (major .isdigit ())
18+ self .assertTrue (minor .isdigit ())
19+ self .assertTrue (patch .isdigit ())
You can’t perform that action at this time.
0 commit comments