simplify config for versioning and pypi upload #1930
Workflow file for this run
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: TestingInConda | |
on: | |
push: | |
branches: | |
- '*' | |
pull_request: | |
branches: | |
- '*' | |
jobs: | |
setup-build: | |
name: Ex1 (${{ matrix.python-version }}, ${{ matrix.os }}) | |
runs-on: ${{ matrix.os }} | |
strategy: | |
fail-fast: false | |
matrix: | |
os: ["ubuntu-latest"] | |
python-version: [3.7, 3.8] | |
steps: | |
- uses: actions/checkout@v2 | |
- name: Setup Conda | |
uses: s-weigand/setup-conda@v1 | |
with: | |
update-conda: true | |
conda-channels: conda-forge | |
python-version: ${{ matrix.python-version }} | |
- name: Install Env | |
shell: bash | |
run: | | |
python --version | |
conda create -n mtmetadata-test | |
source activate mtmetadata-test | |
conda config --add channels conda-forge | |
conda install pytest | |
conda install pytest-cov | |
- name: Install Our Package | |
shell: bash | |
run: | | |
source activate mtmetadata-test | |
pip install -e . | |
conda list | |
- name: Run Tests | |
shell: bash | |
run: | | |
source activate mtmetadata-test | |
pytest --cov=./ --cov-report=xml --cov=mt_metadata | |
- name: "Upload coverage to Codecov" | |
uses: codecov/codecov-action@v1 | |
with: | |
fail_ci_if_error: true |