Skip to content

Commit 1d81295

Browse files
committed
pytest + sphinx-build work, another hack for subpackage test
1 parent aed9f1c commit 1d81295

1 file changed

Lines changed: 4 additions & 3 deletions

File tree

tests/test_project.py

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -33,11 +33,9 @@ def baked_with_development_dependencies(cookies):
3333
result = cookies.bake()
3434
if platform.startswith("win") and os.environ.get('CI', False):
3535
# Creating virtualenv does not work on Windows CI,
36-
# falling back to using current Python
36+
# falling back to using current pip3 dir
3737
pip = Path(which('pip3'))
3838
bin_dir = str(pip.parent) + '\\'
39-
print(bin_dir)
40-
print(list(Path(bin_dir).iterdir()))
4139
else:
4240
env_output = run(['python3', '-m', 'venv', 'env'], result.project)
4341
assert env_output.returncode == 0
@@ -68,6 +66,9 @@ def test_subpackage(baked_with_development_dependencies):
6866
subsubpackage.mkdir()
6967
(subsubpackage / '__init__.py').write_text('FOO = "bar"', encoding="utf-8")
7068

69+
if platform.startswith("win") and os.environ.get('CI', False):
70+
# On Windows CI python and pip executable are in different paths
71+
bin_dir = ''
7172
build_output = run([f'{bin_dir}python', 'setup.py', 'build'], project_dir)
7273
assert build_output.returncode == 0
7374
assert (project_dir / 'build' / 'lib' / 'my_python_package' / 'mysub' / '__init__.py').exists()

0 commit comments

Comments
 (0)