File tree 4 files changed +10
-34
lines changed 4 files changed +10
-34
lines changed Original file line number Diff line number Diff line change @@ -6,10 +6,11 @@ Unreleased (to be updated...)
6
6
7
7
* Added the **unittest_expander.__version__ ** global constant.
8
8
9
- * Tests-and-CI-related improvements and additions -- in particular:
10
- added a script that checks whether **unittest_expander.__version__ **
11
- is equal to **version ** in package metadata, and added invocation of
12
- that script to the *Install and Test * GitHub workflow.
9
+ * improvements and additions related to tests, CI, generation of
10
+ documentation, etc.; in particular: added a script that checks whether
11
+ *unittest_expander.__version__* * is equal to **version ** in package
12
+ metadata, and added invocation of that script to the *Install and
13
+ Test * GitHub workflow.
13
14
14
15
* Documentation: improvements and minor fixes.
15
16
Original file line number Diff line number Diff line change 14
14
15
15
import sys
16
16
import os
17
- import os .path as osp
18
- import re
19
-
20
-
21
- VERSION_LINE_REGEX = re .compile (br'''
22
- ^
23
- version
24
- \s*
25
- =
26
- \s*
27
- (?P<version_str>
28
- \S+
29
- )
30
- \s*
31
- $
32
- ''' , re .VERBOSE )
33
-
34
-
35
- def get_version_str ():
36
- setup_cfg_path = osp .join (os .pardir , 'setup.cfg' )
37
- with open (setup_cfg_path , 'rb' ) as f :
38
- for line in f :
39
- match = VERSION_LINE_REGEX .search (line )
40
- if match :
41
- return match .group ('version_str' ).decode ('utf-8' )
42
- raise AssertionError ('version not found' )
43
-
44
17
45
18
# If extensions (or modules to document with autodoc) are in another directory,
46
19
# add these directories to sys.path here. If the directory is relative to the
47
20
# documentation root, use os.path.abspath to make it absolute, like shown here.
48
21
#sys.path.insert(0, os.path.abspath('.'))
49
22
sys .path .insert (0 , os .path .abspath (os .pardir ))
50
23
24
+ import unittest_expander
25
+
51
26
# -- General configuration ------------------------------------------------
52
27
53
28
# If your documentation needs a minimal Sphinx version, state it here.
@@ -82,7 +57,7 @@ def get_version_str():
82
57
# built documents.
83
58
#
84
59
# The full version, including alpha/beta/rc tags.
85
- release = get_version_str ()
60
+ release = unittest_expander . __version__
86
61
# The short X.Y version.
87
62
version = '.' .join (release .split ('.' )[:2 ])
88
63
Original file line number Diff line number Diff line change 1
1
[metadata]
2
2
name = unittest_expander
3
- version = 0.4.1rc1
3
+ version = 0.4.1rc2
4
4
description = Easy and flexible unit test parametrization
5
5
long_description = file: README.rst
6
6
long_description_content_type = text/x-rst
Original file line number Diff line number Diff line change 2687
2687
'Substitute' ,
2688
2688
)
2689
2689
2690
- __version__ = '0.4.1rc1 '
2690
+ __version__ = '0.4.1rc2 '
2691
2691
2692
2692
2693
2693
_CLASS_TYPES = (type ,) if _PY3 else (type , types .ClassType )
You can’t perform that action at this time.
0 commit comments