Skip to content

Commit

Permalink
ci: Run Python unit and functional tests together (#959)
Browse files Browse the repository at this point in the history
  • Loading branch information
cecheta authored May 22, 2024
1 parent 96cc779 commit 44af6fd
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 4 deletions.
6 changes: 2 additions & 4 deletions .github/workflows/tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -77,8 +77,8 @@ jobs:
fi
echo "MIN_COVERAGE=$MIN_COVERAGE" >> "$GITHUB_OUTPUT"
- name: Run Unit tests
run: make unittest optional_args="--junitxml=coverage-junit.xml --cov=. --cov-report xml:coverage.xml --cov-fail-under ${{ steps.coverage-value.outputs.MIN_COVERAGE }}"
- name: Run Python Tests
run: make python-test optional_args="--junitxml=coverage-junit.xml --cov=. --cov-report xml:coverage.xml --cov-fail-under ${{ steps.coverage-value.outputs.MIN_COVERAGE }}"
- uses: actions/upload-artifact@v4
if: ${{ !cancelled() }}
with:
Expand All @@ -87,8 +87,6 @@ jobs:
coverage-junit.xml
coverage.xml
if-no-files-found: error
- name: Run Functional tests
run: make functionaltest
- name: Setup node
uses: actions/setup-node@v4
with:
Expand Down
4 changes: 4 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,10 @@ build-frontend: ## 🏗️ Build the Frontend webapp
@echo -e "\e[34m$@\e[0m" || true
@cd code/frontend && npm install && npm run build

python-test: ## 🧪 Run Python unit + functional tests
@echo -e "\e[34m$@\e[0m" || true
@poetry run pytest -m "not azure" $(optional_args)

unittest: ## 🧪 Run the unit tests
@echo -e "\e[34m$@\e[0m" || true
@poetry run pytest -m "not azure and not functional" $(optional_args)
Expand Down

0 comments on commit 44af6fd

Please sign in to comment.