Merge pull request #221 from phac-nml/development #422
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Integration Tests | |
on: | |
pull_request: # Run on all pull requests | |
push: | |
branches: # Run on any push to master and development | |
- master | |
- development | |
schedule: # Run weekly on master and development | |
- cron: 0 2 * * 0 | |
branches: master | |
- cron: 0 2 * * 0 | |
branches: development | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
env: | |
DATABASE_COMMITS: '--resfinder-commit d1e607b8989260c7b6a3fbce8fa3204ecfc09022 --pointfinder-commit 694919f59a38980204009e7ade76bf319cb7df0b --plasmidfinder-commit c18e08c17a5988d4f075fc1171636e47546a323d' | |
strategy: | |
fail-fast: False | |
matrix: | |
include: | |
- python-version: "3.9" | |
other-packages: "mlst numpy pandas" | |
steps: | |
- uses: actions/checkout@v2 | |
- name: Setup Conda with Python ${{ matrix.python-version }} | |
uses: conda-incubator/setup-miniconda@v2 | |
with: | |
miniconda-version: "latest" | |
activate-environment: staramr-env | |
python-version: ${{ matrix.python-version }} | |
- name: Install conda packages | |
shell: bash -l {0} | |
run: | | |
conda info | |
conda list | |
conda config --add channels defaults | |
conda config --add channels conda-forge | |
conda config --add channels bioconda | |
conda install -n base conda-libmamba-solver | |
conda config --set solver libmamba | |
conda install Cython blast git perl-list-moreutils ${{ matrix.other-packages }} -y | |
- name: Setup python packages | |
shell: bash -l {0} | |
run: | | |
python --version | |
python setup.py -q install | |
- name: Build database | |
shell: bash -l {0} | |
run: staramr db build --dir staramr/databases/data ${{ env.DATABASE_COMMITS }} | |
- name: Run Tests | |
shell: bash -l {0} | |
run: | | |
pip install pytest | |
pytest |