Skip to content

Commit 7a6108e

Browse files
authored
ci ctest enhancements (fortran-lang#92)
Merge [scivision:citime] into master [scivision:citime]: https://github.com/scivision/stdlib/tree/citime
2 parents e2b0cda + a606606 commit 7a6108e

File tree

2 files changed

+11
-3
lines changed

2 files changed

+11
-3
lines changed

.github/workflows/CI.yml

+8-2
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@ env:
77
CMAKE_BUILD_PARALLEL_LEVEL: "2" # 2 cores on each GHA VM, enable parallel builds
88
CTEST_OUTPUT_ON_FAILURE: "ON" # This way we don't need a flag to ctest
99
CTEST_PARALLEL_LEVEL: "2"
10+
CTEST_TIME_TIMEOUT: "5" # some failures hang forever
1011
HOMEBREW_NO_ANALYTICS: "ON" # Make Homebrew installation a little quicker
1112
HOMEBREW_NO_AUTO_UPDATE: "ON"
1213
HOMEBREW_NO_BOTTLE_SOURCE_FALLBACK: "ON"
@@ -55,10 +56,15 @@ jobs:
5556
run: cmake -Wdev -DCMAKE_BUILD_TYPE=Release -S . -B build
5657

5758
- name: Build and compile
58-
run: cmake --build build || cmake --build build --verbose --parallel 1
59+
run: cmake --build build
60+
61+
- name: catch build fail
62+
run: cmake --build build --verbose --parallel 1
63+
if: failure()
5964

6065
- name: test
61-
run: cmake --build build --target test
66+
run: ctest --parallel --output-on-failure
67+
working-directory: build
6268

6369
- name: Test in-tree builds
6470
if: contains( matrix.gcc_v, '9') # Only test one compiler on each platform

.github/workflows/ci_windows.yml

+3-1
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@ on: [push, pull_request]
44

55
env:
66
CI: "ON"
7+
CTEST_TIME_TIMEOUT: "5" # some failures hang forever
78

89
jobs:
910
Build:
@@ -24,7 +25,8 @@ jobs:
2425
- name: CMake build
2526
run: cmake --build build --parallel
2627

27-
- run: cmake --build build --verbose --parallel 1
28+
- name: catch build fail
29+
run: cmake --build build --verbose --parallel 1
2830
if: failure()
2931

3032
- name: CTest

0 commit comments

Comments
 (0)