Print slow tests in CI (#2082)

Co-authored-by: Chi Wang <wang.chi@microsoft.com>
This commit is contained in:
Jack Gerrits 2024-03-20 18:27:35 -04:00 committed by GitHub
parent 7739632ef2
commit 2ad016d18d
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with 5 additions and 5 deletions

View File

@ -57,16 +57,16 @@ jobs:
- name: Test with pytest skipping openai tests
if: matrix.python-version != '3.10' && matrix.os == 'ubuntu-latest'
run: |
pytest test --skip-openai
pytest test --skip-openai --durations=10 --durations-min=1.0
- name: Test with pytest skipping openai and docker tests
if: matrix.python-version != '3.10' && matrix.os != 'ubuntu-latest'
run: |
pytest test --skip-openai --skip-docker
pytest test --skip-openai --skip-docker --durations=10 --durations-min=1.0
- name: Coverage
if: matrix.python-version == '3.10'
run: |
pip install -e .[test,redis]
coverage run -a -m pytest test --ignore=test/agentchat/contrib --skip-openai
coverage run -a -m pytest test --ignore=test/agentchat/contrib --skip-openai --durations=10 --durations-min=1.0
coverage xml
- name: Upload coverage to Codecov
if: matrix.python-version == '3.10'

View File

@ -63,7 +63,7 @@ jobs:
AZURE_OPENAI_API_BASE: ${{ secrets.AZURE_OPENAI_API_BASE }}
OAI_CONFIG_LIST: ${{ secrets.OAI_CONFIG_LIST }}
run: |
coverage run -a -m pytest test --ignore=test/agentchat/contrib
coverage run -a -m pytest test --ignore=test/agentchat/contrib --durations=10 --durations-min=1.0
coverage xml
- name: Coverage and check notebook outputs
if: matrix.python-version != '3.9'
@ -75,7 +75,7 @@ jobs:
OAI_CONFIG_LIST: ${{ secrets.OAI_CONFIG_LIST }}
run: |
pip install nbconvert nbformat ipykernel
coverage run -a -m pytest test/test_notebook.py
coverage run -a -m pytest test/test_notebook.py --durations=10 --durations-min=1.0
coverage xml
cat "$(pwd)/test/executed_openai_notebook_output.txt"
- name: Upload coverage to Codecov