Instead of checking for Jython, make it possible to opt-out from the Cython test
- we don't have Jython any more and even if we had, we could explicitly opt out from it - we sometimes need to opt out from Cython test in the development versions of Python
This commit is contained in:
parent
bc948d6e50
commit
362f438cc6
2 changed files with 7 additions and 4 deletions
|
|
@ -8,6 +8,7 @@ VERSION=${VERSION:-3.8}
|
|||
PYTHON=${PYTHON:-python$VERSION}
|
||||
METHOD=${METHOD:-venv}
|
||||
TOX=${TOX:-true}
|
||||
CYTHON=${CYTHON:-true}
|
||||
INSTALL_OR_SKIP=${INSTALL_OR_SKIP:-false}
|
||||
|
||||
# clean from possible older runs
|
||||
|
|
@ -52,10 +53,12 @@ if [ "$VERSION" == "2.6" ]; then
|
|||
elif [ "$VERSION" == "3.11" ]; then
|
||||
python -m pip install pytest
|
||||
# Cython support for 3.11.0a1+ is not yet released
|
||||
python -m pip install https://github.com/cython/cython/archive/master.tar.gz --install-option="--no-cython-compile"
|
||||
if [ "$CYTHON" == "true" ]; then
|
||||
python -m pip install https://github.com/cython/cython/archive/master.tar.gz --install-option="--no-cython-compile"
|
||||
fi
|
||||
else
|
||||
python -m pip install pytest
|
||||
if [ "$PYTHON" != "jython" ]; then
|
||||
if [ "$CYTHON" == "true" ]; then
|
||||
# We try to fetch a wheel only and if that fails, we disable compilation
|
||||
# Useful for fresh CPythons, where wheels are not yet ready, but Cython defaults to compiling
|
||||
python -m pip install Cython --only-binary :all: || python -m pip install Cython --install-option="--no-cython-compile"
|
||||
|
|
@ -70,7 +73,7 @@ EOF
|
|||
|
||||
python -m pytest -v test_foo.py
|
||||
|
||||
if [ "$PYTHON" != "jython" ]; then
|
||||
if [ "$CYTHON" == "true" ]; then
|
||||
cat > module.pyx << EOF
|
||||
cdef int add(int a, int b):
|
||||
return a + b
|
||||
|
|
|
|||
|
|
@ -39,7 +39,7 @@
|
|||
run: VERSION=3.9 METHOD=venv ./venv.sh
|
||||
- smoke311:
|
||||
dir: smoke
|
||||
run: VERSION=3.11 METHOD=venv ./venv.sh
|
||||
run: VERSION=3.11 METHOD=venv CYTHON=false ./venv.sh
|
||||
- smoke39_seeder_pip:
|
||||
dir: smoke
|
||||
run: VERSION=3.9 METHOD=virtualenv-seeder-pip ./venv.sh
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue