File tree Expand file tree Collapse file tree 1 file changed +7
-7
lines changed Expand file tree Collapse file tree 1 file changed +7
-7
lines changed Original file line number Diff line number Diff line change 10
10
11
11
DOCS_DIR = "docs"
12
12
TEST_DIR = "tests"
13
- SDIST_FILE = f"{ __title__ } -{ __version__ } .tar.gz"
14
- WHEEL_FILE = f"{ __title__ .replace ('-' , '_' )} -{ __version__ } -py{ sys .version_info .major } -none-any.whl"
13
+ DIST_NORMALIZED_TITLE = f"{ __title__ .replace ('-' , '_' )} -{ __version__ } "
14
+ SDIST_FILE = f"{ DIST_NORMALIZED_TITLE } .tar.gz"
15
+ WHEEL_FILE = f"{ DIST_NORMALIZED_TITLE } -py{ sys .version_info .major } -none-any.whl"
15
16
PY_TYPED = "gitlab/py.typed"
16
17
17
18
@@ -24,12 +25,11 @@ def build(tmp_path_factory: pytest.TempPathFactory):
24
25
25
26
def test_sdist_includes_correct_files (build : Path ) -> None :
26
27
sdist = tarfile .open (build / SDIST_FILE , "r:gz" )
27
- sdist_dir = f"{ __title__ } -{ __version__ } "
28
28
29
- docs_dir = sdist .getmember (f"{ sdist_dir } /{ DOCS_DIR } " )
30
- test_dir = sdist .getmember (f"{ sdist_dir } /{ TEST_DIR } " )
31
- readme = sdist .getmember (f"{ sdist_dir } /README.rst" )
32
- py_typed = sdist .getmember (f"{ sdist_dir } /{ PY_TYPED } " )
29
+ docs_dir = sdist .getmember (f"{ DIST_NORMALIZED_TITLE } /{ DOCS_DIR } " )
30
+ test_dir = sdist .getmember (f"{ DIST_NORMALIZED_TITLE } /{ TEST_DIR } " )
31
+ readme = sdist .getmember (f"{ DIST_NORMALIZED_TITLE } /README.rst" )
32
+ py_typed = sdist .getmember (f"{ DIST_NORMALIZED_TITLE } /{ PY_TYPED } " )
33
33
34
34
assert docs_dir .isdir ()
35
35
assert test_dir .isdir ()
You can’t perform that action at this time.
0 commit comments