Skip to content

Commit

Permalink
Merge pull request #690 from voidking/unittest
Browse files Browse the repository at this point in the history
pr trigger unittest, maintainer approve the unittest
  • Loading branch information
geekan committed Jan 5, 2024
2 parents 230192f + 3fc2fea commit afa2411
Show file tree
Hide file tree
Showing 2 changed files with 18 additions and 1 deletion.
17 changes: 17 additions & 0 deletions .github/workflows/unittest.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,21 @@ name: Python application test

on:
workflow_dispatch:
pull_request:
branches:
- 'main'
- 'dev'
- '*-release'
push:
branches:
- 'main'
- 'dev'
- '*-release'

jobs:
build:
runs-on: ubuntu-latest
environment: unittest
strategy:
matrix:
# python-version: ['3.9', '3.10', '3.11']
Expand All @@ -30,6 +41,11 @@ jobs:
- name: Show failed tests and overall summary
run: |
grep -E "FAILED tests|[0-9]+ passed," unittest.txt
failed_count=$(grep "FAILED" unittest.txt | wc -l)
if [[ "$failed_count" -gt 0 ]]; then
echo "$failed_count failed lines found! Task failed."
exit 1
fi
- name: Upload pytest test results
uses: actions/upload-artifact@v3
with:
Expand All @@ -40,4 +56,5 @@ jobs:
./tests/data/rsp_cache_new.json
retention-days: 3
if: ${{ always() }}


2 changes: 1 addition & 1 deletion tests/scripts/run_install_deps.sh
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
python -m pip install --upgrade pip
pip install -e .[test]
npm install -g @mermaid-js/mermaid-cli
playwright install --with-deps chromium
playwright install --with-deps

0 comments on commit afa2411

Please sign in to comment.