Skip to content

remove osp from test.py #1155

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Nov 22, 2022
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 7 additions & 3 deletions test.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,8 @@

import sys
import os
import os.path as osp
# import os.path as osp
from pathlib import Path
import re

# Local imports
Expand All @@ -25,9 +26,12 @@ def test_python_packages(pyver):
"""Check if all Python packages are supported by WinPython"""
basedir = utils.get_basedir(pyver)
for suffix in ('src', 'win32', 'win-amd64'):
dirname = osp.join(basedir, 'packages.%s' % suffix)
# dirname = osp.join(basedir, 'packages.%s' % suffix)
dirname = str(Path(basedir) / f'packages.{suffix}')
for name in os.listdir(dirname):
if osp.isfile(osp.join(dirname, name)) \
# if osp.isfile(osp.join(dirname, name)) \
# if osp.isfile(str(Path(dirname) / name)) \
if (Path(dirname) / name).is_file() \
and not re.match(r'python-([0-9\.]*)(\.amd64)?\.msi', name):
try:
print(wppm.Package(name))
Expand Down