Allow to test Jython
METHOD=virtualenv PYTHON=jython VERSION=2.7 ./smoke/venv.sh
This commit is contained in:
parent
b3d405a516
commit
c56363e23a
1 changed files with 6 additions and 1 deletions
|
|
@ -34,7 +34,10 @@ if [ "$VERSION" == "2.6" ]; then
|
|||
pip install pytest
|
||||
pip install Cython --install-option="--no-cython-compile"
|
||||
else
|
||||
python -m pip install pytest Cython
|
||||
python -m pip install pytest
|
||||
if [ "$PYTHON" != "jython" ]; then
|
||||
python -m pip install Cython
|
||||
fi
|
||||
fi
|
||||
|
||||
# run tests
|
||||
|
|
@ -46,6 +49,7 @@ EOF
|
|||
python -m pytest -v test_foo.py
|
||||
|
||||
# check that we can do extension modules
|
||||
if [ "$PYTHON" != "jython" ]; then
|
||||
cat > module.pyx << EOF
|
||||
cdef int add(int a, int b):
|
||||
return a + b
|
||||
|
|
@ -66,6 +70,7 @@ EOF
|
|||
python setup.py build_ext --inplace
|
||||
|
||||
python -c 'import module; print(module.two())' | grep '^2$'
|
||||
fi
|
||||
|
||||
# deactivate has unset variable, it's known
|
||||
set +u
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue