File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 1+ name : Run tests
2+
3+ on :
4+ push :
5+ branches : [master, main]
6+ pull_request :
7+ branches : [master, main]
8+
9+ jobs :
10+ test :
11+ runs-on : ubuntu-latest
12+ permissions :
13+ contents : read
14+
15+ steps :
16+ - uses : actions/checkout@v4
17+
18+ - name : Install dependencies
19+ run : |
20+ sudo apt-get update
21+ sudo apt-get install -y shellcheck cppcheck
22+
23+ - name : Bootstrap
24+ run : ./bootstrap.sh
25+
26+ - name : Configure
27+ run : ./configure --enable-debug
28+
29+ - name : Build
30+ run : make -j$(nproc)
31+
32+ - name : Run tests
33+ run : make check
34+
35+ - name : Upload test logs on failure
36+ if : failure()
37+ uses : actions/upload-artifact@v4
38+ with :
39+ name : test-logs
40+ path : tests/testsuite.log
Original file line number Diff line number Diff line change 1- name : Check formatting on sources
1+ name : Check formatting
22
33on :
44 push :
1515 steps :
1616 - uses : actions/checkout@v4
1717 - name : Install dependencies
18- run : sudo apt install shfmt clang-format
18+ run : sudo apt -y install shfmt clang-format
1919 - name : Initial setup
2020 run : ./bootstrap.sh
2121 - name : Configure
Original file line number Diff line number Diff line change @@ -291,20 +291,6 @@ AT_CLEANUP
291291
292292########################################
293293
294- AT_SETUP([Check formatting on C code])
295-
296- # Skip if clang-format is not installed
297- AT_SKIP_IF([! command -v clang-format])
298-
299- # Run clang-format on all source files
300- for file in "$abs_top_builddir"/**/*.{c,h}; do
301- AT_CHECK([clang-format --dry-run --Werror "$file"])
302- done
303-
304- AT_CLEANUP
305-
306- ########################################
307-
308294AT_SETUP([Static check C code])
309295
310296# Skip if cppcheck is not installed
@@ -319,20 +305,6 @@ AT_CLEANUP
319305
320306########################################
321307
322- AT_SETUP([Check formatting on shell scripts])
323-
324- # Skip if shfmt is not installed
325- AT_SKIP_IF([! command -v shfmt])
326-
327- # Run shfmt on all shell files
328- for file in "$abs_top_builddir"/**/*.sh; do
329- AT_CHECK([shfmt --diff "$file"])
330- done
331-
332- AT_CLEANUP
333-
334- ########################################
335-
336308AT_SETUP([Static check shell scripts])
337309
338310# Skip if shellcheck is not installed
You can’t perform that action at this time.
0 commit comments