Skip to content

Commit

Permalink
tests: Add timeout to .gunittest.cfg file (#1318)
Browse files Browse the repository at this point in the history
* tests: Add timeout to .gunittest.cfg file

* tests: Increase timeout to 6 minutes per file
  • Loading branch information
echoix authored Feb 16, 2025
1 parent bf40491 commit 6cb3328
Show file tree
Hide file tree
Showing 3 changed files with 15 additions and 2 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -132,7 +132,7 @@ jobs:
timeout-minutes: 45
run: |
cd grass-addons/src
../.github/workflows/test.sh
../.github/workflows/test.sh --config ../.gunittest.cfg
- name: Make HTML test report available
uses: actions/upload-artifact@65c4c4a1ddee5b72f698fdd19549f0f0fb45cf08 # v4.6.0
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/test.sh
Original file line number Diff line number Diff line change
Expand Up @@ -16,4 +16,4 @@ grass --tmp-project XY --exec \
grass --tmp-project XY --exec \
python3 -m grass.gunittest.main \
--grassdata $HOME --location nc_spm_full_v2alpha2 --location-type nc \
--min-success 60
--min-success 60 $@
13 changes: 13 additions & 0 deletions .gunittest.cfg
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
[gunittest]

# Files (or wildcard patterns) to exclude from testing separated by newline or
# space. This would be ideally empty or it would include just special cases,
# but it includes mainly tests which can (and should) be fixed.
# exclude =

# Maximum time for execution of one test file (not a test function)
# after which test is terminated (which may not terminate child processes
# from that test).
# Using 6 minutes as maximum (average test time should be much shorter,
# couple seconds per file, median should be around one second).
timeout = 360

0 comments on commit 6cb3328

Please sign in to comment.