Skip to content

Commit

Permalink
Merge pull request #236 from medema-group/hotfix/pytest-all-branches
Browse files Browse the repository at this point in the history
split tests from badges workflow
  • Loading branch information
adraismawur authored Dec 19, 2024
2 parents a9e9834 + b05cf98 commit dc5ffbd
Show file tree
Hide file tree
Showing 2 changed files with 38 additions and 28 deletions.
28 changes: 0 additions & 28 deletions .github/workflows/badges.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,34 +5,6 @@ on:
branches:
- master

jobs:
run_pytest:
runs-on: ubuntu-latest
if: ${{ !contains(github.event.head_commit.message, 'docs') && !contains(github.event.head_commit.message, 'documentation') }}
timeout-minutes: 15
steps:
- name: Checkout code
uses: actions/checkout@v3

- name: Set up mamba environment
uses: mamba-org/setup-micromamba@v1
with:
micromamba-version: '1.3.1-0'
environment-file: environment.yml
environment-name: BiG-SCAPE
init-shell: bash
generate-run-shell: true

- name: Install dependencies
shell: micromamba-shell {0}
run: |
python -m pip install pytest
- name: Test with Pytest
shell: micromamba-shell {0}
run: |
pytest
generate_coverage:
runs-on: ubuntu-latest
if: ${{ !contains(github.event.head_commit.message, 'docs') && !contains(github.event.head_commit.message, 'documentation') }}
Expand Down
38 changes: 38 additions & 0 deletions .github/workflows/run-tests.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
name: Run tests

on:
push:
branches:
- master
- dev
- release/*
- feature/*
- hotfix/*

jobs:
run_pytest:
runs-on: ubuntu-latest
if: ${{ !contains(github.event.head_commit.message, 'docs') && !contains(github.event.head_commit.message, 'documentation') }}
timeout-minutes: 15
steps:
- name: Checkout code
uses: actions/checkout@v3

- name: Set up mamba environment
uses: mamba-org/setup-micromamba@v1
with:
micromamba-version: '1.3.1-0'
environment-file: environment.yml
environment-name: BiG-SCAPE
init-shell: bash
generate-run-shell: true

- name: Install dependencies
shell: micromamba-shell {0}
run: |
python -m pip install pytest
- name: Test with Pytest
shell: micromamba-shell {0}
run: |
pytest

0 comments on commit dc5ffbd

Please sign in to comment.