Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
fengzch-das
multibuild
Commits
24936a2a
Commit
24936a2a
authored
Oct 01, 2018
by
Matthew Brett
Browse files
Add test for supported_wheels, with fix
parent
0623c582
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
20 additions
and
2 deletions
+20
-2
supported_wheels.py
supported_wheels.py
+3
-2
tests/test_multibuild.sh
tests/test_multibuild.sh
+2
-0
tests/test_supported_wheels.sh
tests/test_supported_wheels.sh
+15
-0
No files found.
supported_wheels.py
View file @
24936a2a
...
@@ -7,9 +7,10 @@ import sys
...
@@ -7,9 +7,10 @@ import sys
from
os.path
import
basename
from
os.path
import
basename
try
:
try
:
from
wheel.install
import
WHEEL_INFO_RE
from
wheel.install
import
WHEEL_INFO_RE
as
wheel_matcher
except
ImportError
:
# As of Wheel 0.32.0
except
ImportError
:
# As of Wheel 0.32.0
from
wheel.wheelfile
import
WHEEL_INFO_RE
from
wheel.wheelfile
import
WHEEL_INFO_RE
wheel_matcher
=
WHEEL_INFO_RE
.
match
try
:
try
:
from
pip.pep425tags
import
get_supported
from
pip.pep425tags
import
get_supported
except
ImportError
:
# pip 10
except
ImportError
:
# pip 10
...
@@ -18,7 +19,7 @@ except ImportError: # pip 10
...
@@ -18,7 +19,7 @@ except ImportError: # pip 10
def
tags_for
(
fname
):
def
tags_for
(
fname
):
# Copied from WheelFile code
# Copied from WheelFile code
parsed_filename
=
WHEEL_INFO_RE
.
match
(
basename
(
fname
))
parsed_filename
=
wheel_
match
er
(
basename
(
fname
))
tags
=
parsed_filename
.
groupdict
()
tags
=
parsed_filename
.
groupdict
()
for
pyver
in
tags
[
'pyver'
].
split
(
'.'
):
for
pyver
in
tags
[
'pyver'
].
split
(
'.'
):
for
abi
in
tags
[
'abi'
].
split
(
'.'
):
for
abi
in
tags
[
'abi'
].
split
(
'.'
):
...
...
tests/test_multibuild.sh
View file @
24936a2a
...
@@ -29,6 +29,8 @@ if [ -n "$TEST_BUILDS" ]; then
...
@@ -29,6 +29,8 @@ if [ -n "$TEST_BUILDS" ]; then
fi
fi
fi
fi
source
tests/test_supported_wheels.sh
# Exit 1 if any test errors
# Exit 1 if any test errors
barf
barf
# Don't need Travis' machinery trace
# Don't need Travis' machinery trace
...
...
tests/test_supported_wheels.sh
0 → 100644
View file @
24936a2a
# Test supported wheels script
PYTHON_EXE
=
${
PYTHON_EXE
:-
python
}
if
[
-z
"
$PIP_CMD
"
]
;
then
pip_install
=
"pip install --user"
else
pip_install
=
"
$PIP_CMD
install"
fi
# Current wheel versions not available for older Pythons
lpv
=
$(
lex_ver
$PYTHON_VERSION
)
if
[
$lpv
-ge
$(
lex_ver 3.5
)
]
||
[
$lpv
-lt
$(
lex_ver 3
)
]
;
then
for
whl
in
wheel
==
0.31.1
wheel
==
0.32.0 wheel
;
do
$pip_install
-U
$whl
$PYTHON_EXE
supported_wheels.py tornado-5.1-cp27-cp27m-macosx_10_6_intel.whl tornado-5.1-cp36-cp36m-macosx_10_13_x86_64.whl texext-0.6.1-cp36-none-any.whl
done
fi
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment