Skip to content

Commit

Permalink
Run python tests with timeout
Browse files Browse the repository at this point in the history
  • Loading branch information
talregev committed Jan 7, 2024
1 parent 7cd46f8 commit f797a90
Show file tree
Hide file tree
Showing 4 changed files with 5 additions and 3 deletions.
4 changes: 3 additions & 1 deletion .github/scripts/python.sh
Original file line number Diff line number Diff line change
Expand Up @@ -70,8 +70,10 @@ function build()

function test()
{
$PYTHON -m pip install --user pytest-timeout
cd $GITHUB_WORKSPACE/python/gtsam/tests
$PYTHON -m unittest discover -v
# run tests with timeout (10 sec). (Reveal the test that hang on tbb)
$PYTHON -m pytest --verbose --timeout=10 --timeout-method=thread
cd $GITHUB_WORKSPACE
}

Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/build-python.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ jobs:
PYTHON_VERSION: ${{ matrix.python_version }}

strategy:
fail-fast: true
fail-fast: false
matrix:
# Github Actions requires a single row to be added to the build matrix.
# See https://help.github.com/en/articles/workflow-syntax-for-github-actions.
Expand Down Expand Up @@ -107,7 +107,7 @@ jobs:
if: runner.os == 'Linux'
uses: pierotofy/set-swap-space@master
with:
swap-size-gb: 6
swap-size-gb: 10

- name: Install System Dependencies
run: |
Expand Down
File renamed without changes.

0 comments on commit f797a90

Please sign in to comment.