@@ -11,59 +11,28 @@ jobs:
1111 strategy :
1212 max-parallel : 4
1313 matrix :
14- include :
15- - python-version : 3.6
16- - python-version : 3.7
17- - python-version : 3.8
18- # make sure it works without pandas
19- - python-version : 3.6
20- pandas-version-string : " NONE"
21- - python-version : 3.7
22- pandas-version-string : " NONE"
23- - python-version : 3.8
24- pandas-version-string : " NONE"
14+ python-version : [3.6, 3.7, 3.8]
15+ pandas-presence : ['with_pandas', 'without_pandas']
2516 env :
2617 PYTHON_VERSION : ${{ matrix.python-version }}
27- PANDAS_VERSION_STR : ${{ matrix.pandas-version-string }}
28- # Work around terrible pathological behaviour in OpenBLAS/MKL/VML multithreading, that causes
29- # execution time to blow up from 3 minutes to 18 minutes, apparently in SVD on smallish matrices
30- OMP_NUM_THREADS : 1
31- MKL_NUM_THREADS : 1
32- VML_NUM_THREADS : 1
18+ PANDAS_PRESENCE : ${{ matrix.pandas-presence }}
3319 steps :
3420 - uses : actions/checkout@v1
35- - name : Set up Miniconda environment for Python ${{ matrix.python-version }}
36- uses : conda-incubator /setup-miniconda@v2
21+ - name : Set up Python ${{ matrix.python-version }}
22+ uses : actions /setup-python@v1
3723 with :
38- miniforge-variant : Mambaforge
39- activate-environment : patsy
40- auto-update-conda : true
41- channels : conda-forge
42- channel-priority : flexible
4324 python-version : ${{ matrix.python-version }}
44- - name : Install conda dependencies
45- shell : bash -l {0}
25+ - name : Install dependencies
4626 run : |
47- export PKGS="numpy scipy pytest pytest-cov pip"
48- if [ "$PANDAS_VERSION_STR" != "NONE" ]; then export PKGS="${PKGS} pandas${PANDAS_VERSION_STR}"; fi
49- mamba install -y $PKGS
50- - name : Install patsy
51- shell : bash -l {0}
27+ python -m pip install --upgrade pip
28+ pip install tox
29+ - name : Test with tox
5230 run : |
53- python setup.py sdist
54- pip install dist/*
55- - name : Run tests
56- shell : bash -l {0}
57- run : |
58- mkdir empty
59- cd empty
60- INSTALLDIR=$(python -c "import os; import patsy; print(os.path.dirname(patsy.__file__))")
61- export PYTHONWARNINGS=default PATSY_FORCE_NO_WARNINGS=1
62- pytest -vv -c ../setup.cfg --cov=$INSTALLDIR --cov-config=../.coveragerc --cov-report=term-missing --cov-report=xml $INSTALLDIR
63- python ../tools/check-API-refs.py
31+ PYTHON_ENV="py${PYTHON_VERSION//./}"
32+ tox -e "${PYTHON_ENV}-${PANDAS_PRESENCE}"
6433 - name : Upload coverage to Codecov
6534 uses : codecov/codecov-action@v1.0.10
6635 with :
67- file : ./empty/ coverage.xml
36+ file : ./coverage.xml
6837 flags : unittests
69- env_vars : PYTHON_VERSION,PANDAS_VERSION_STR
38+ env_vars : PYTHON_VERSION,PANDAS_PRESENCE
0 commit comments