Skip to content

Commit e5195d6

Browse files
committed
Replaced test scripts with autotest
1 parent 8b1b60c commit e5195d6

35 files changed

Lines changed: 1798 additions & 1988 deletions

.github/workflows/build_freebsd.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ jobs:
1919
usesh: true
2020
mem: 4096
2121
prepare: |
22-
pkg install -y autoconf automake bash curl fusefs-libs gettext git libtool pkgconf
22+
pkg install -y autoconf automake curl fusefs-libs gettext git libtool pkgconf
2323
- name: Download test data
2424
shell: freebsd {0}
2525
run: |
@@ -32,8 +32,8 @@ jobs:
3232
./synclibs.sh --use-head
3333
./autogen.sh
3434
./configure ${{ matrix.configure_options }}
35-
make > /dev/null
35+
make -j4 > /dev/null
3636
- name: Run tests
3737
shell: freebsd {0}
3838
run: |
39-
tests/runtests.sh CHECK_WITH_STDERR=1
39+
tests/runtests.sh -j4 VERBOSE=1

.github/workflows/build_linux.yml

Lines changed: 13 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -47,10 +47,10 @@ jobs:
4747
./synclibs.sh --use-head
4848
./autogen.sh
4949
./configure ${{ matrix.configure_options }}
50-
make > /dev/null
50+
make -j4 > /dev/null
5151
- name: Run tests
5252
run: |
53-
tests/runtests.sh CHECK_WITH_STDERR=1
53+
tests/runtests.sh -j4 VERBOSE=1
5454
build_dist:
5555
runs-on: ${{ matrix.os }}
5656
strategy:
@@ -75,10 +75,10 @@ jobs:
7575
./synclibs.sh --use-head
7676
./autogen.sh
7777
./configure ${{ matrix.configure_options }}
78-
make > /dev/null
78+
make -j4 > /dev/null
7979
- name: Run tests
8080
run: |
81-
make distcheck VERBOSE=1
81+
make distcheck AM_MAKEFLAGS="-j4" VERBOSE=1
8282
build_fuse:
8383
runs-on: ${{ matrix.os }}
8484
strategy:
@@ -103,10 +103,10 @@ jobs:
103103
./synclibs.sh --use-head
104104
./autogen.sh
105105
./configure ${{ matrix.configure_options }}
106-
make > /dev/null
106+
make -j4 > /dev/null
107107
- name: Run tests
108108
run: |
109-
tests/runtests.sh CHECK_WITH_STDERR=1
109+
tests/runtests.sh -j4 VERBOSE=1
110110
build_fuse3:
111111
runs-on: ${{ matrix.os }}
112112
strategy:
@@ -131,10 +131,10 @@ jobs:
131131
./synclibs.sh --use-head
132132
./autogen.sh
133133
./configure ${{ matrix.configure_options }}
134-
make > /dev/null
134+
make -j4 > /dev/null
135135
- name: Run tests
136136
run: |
137-
tests/runtests.sh CHECK_WITH_STDERR=1
137+
tests/runtests.sh -j4 VERBOSE=1
138138
build_python:
139139
runs-on: ${{ matrix.os }}
140140
strategy:
@@ -160,12 +160,12 @@ jobs:
160160
./synclibs.sh --use-head
161161
./autogen.sh
162162
./configure ${{ matrix.configure_options }}
163-
make > /dev/null
163+
make -j4 > /dev/null
164164
- name: Run tests
165165
env:
166166
PYTHON_VERSION: ${{ matrix.python_version }}
167167
run: |
168-
tests/runtests.sh CHECK_WITH_STDERR=1
168+
tests/runtests.sh -j4 VERBOSE=1
169169
build_pyproject:
170170
runs-on: ${{ matrix.os }}
171171
strategy:
@@ -187,7 +187,7 @@ jobs:
187187
./synclibs.sh --use-head
188188
./autogen.sh
189189
./configure ${{ matrix.configure_options }}
190-
make > /dev/null
190+
make -j4 > /dev/null
191191
- name: Build Python module
192192
run: |
193193
python -m build
@@ -221,7 +221,7 @@ jobs:
221221
./synclibs.sh --use-head
222222
./autogen.sh
223223
./configure ${{ matrix.configure_options }}
224-
make > /dev/null
224+
make -j4 > /dev/null
225225
- name: Run tests
226226
run: |
227-
tests/runtests.sh CHECK_WITH_STDERR=1
227+
tests/runtests.sh -j4 VERBOSE=1

.github/workflows/build_macos.yml

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -42,10 +42,10 @@ jobs:
4242
./synclibs.sh --use-head
4343
./autogen.sh
4444
./configure ${{ matrix.configure_options }}
45-
make > /dev/null
45+
make -j4 > /dev/null
4646
- name: Run tests
4747
run: |
48-
tests/runtests.sh CHECK_WITH_STDERR=1
48+
tests/runtests.sh -j4 VERBOSE=1
4949
build_macfuse:
5050
runs-on: ${{ matrix.os }}
5151
strategy:
@@ -73,10 +73,10 @@ jobs:
7373
./synclibs.sh --use-head
7474
./autogen.sh
7575
./configure ${{ matrix.configure_options }}
76-
make > /dev/null
76+
make -j4 > /dev/null
7777
- name: Run tests
7878
run: |
79-
tests/runtests.sh CHECK_WITH_STDERR=1
79+
tests/runtests.sh -j4 VERBOSE=1
8080
build_python:
8181
runs-on: ${{ matrix.os }}
8282
strategy:
@@ -102,10 +102,10 @@ jobs:
102102
./synclibs.sh --use-head
103103
./autogen.sh
104104
./configure ${{ matrix.configure_options }}
105-
make > /dev/null
105+
make -j4 > /dev/null
106106
- name: Run tests
107107
run: |
108-
tests/runtests.sh CHECK_WITH_STDERR=1
108+
tests/runtests.sh -j4 VERBOSE=1
109109
build_pkgbuild:
110110
runs-on: ${{ matrix.os }}
111111
strategy:
@@ -131,7 +131,7 @@ jobs:
131131
./synclibs.sh --use-head
132132
./autogen.sh
133133
./configure ${{ matrix.configure_options }}
134-
make > /dev/null
134+
make -j4 > /dev/null
135135
- name: Build pkg
136136
run: |
137137
tests/pkgbuild.sh

.github/workflows/build_windows.yml

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -66,14 +66,14 @@ jobs:
6666
./synclibs.sh --use-head
6767
./autogen.sh
6868
./configure ${CONFIGURE_OPTIONS}
69-
make > /dev/null
69+
make -j4 > /dev/null
7070
- name: Run tests
7171
shell: bash --login -e -o pipefail -o igncr {0}
7272
working-directory: ${{ github.workspace }}
7373
env:
7474
CHERE_INVOKING: 1
7575
run: |
76-
tests/runtests.sh CHECK_WITH_STDERR=1
76+
tests/runtests.sh -j4 VERBOSE=1
7777
build_msys2_mingw:
7878
runs-on: windows-latest
7979
strategy:
@@ -83,6 +83,8 @@ jobs:
8383
- configure_options: '--enable-winapi --enable-wide-character-type'
8484
- configure_options: '--disable-nls --disable-shared-libs --enable-python'
8585
steps:
86+
- name: Configure git
87+
run: git config --global core.autocrlf false
8688
- uses: actions/checkout@v6
8789
- name: Set up MSYS2 with MinGW-w64
8890
uses: msys2/setup-msys2@v2
@@ -102,8 +104,8 @@ jobs:
102104
./synclibs.sh --use-head
103105
./autogen.sh
104106
./configure ${CONFIGURE_OPTIONS}
105-
make > /dev/null
107+
make -j4 > /dev/null
106108
- name: Run tests
107109
shell: msys2 {0}
108110
run: |
109-
tests/runtests.sh CHECK_WITH_STDERR=1
111+
tests/runtests.sh -j4 VERBOSE=1

.github/workflows/check_source.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ jobs:
3333
make > /dev/null
3434
- name: Run tests
3535
run: |
36-
tests/runtests.sh CHECK_WITH_STDERR=1
36+
tests/runtests.sh VERBOSE=1
3737
scan_build:
3838
name: Check source with scan-build
3939
runs-on: ${{ matrix.os }}
@@ -86,7 +86,7 @@ jobs:
8686
]
8787
}
8888
run: |
89-
npx @microsoft/sarif-multitool merge scan-results/*/*.sarif --merge-runs --output-file=scan-build-report.sarif
89+
npx @microsoft/sarif-multitool merge scan-results/*/*.sarif --output-file=scan-build-report.sarif
9090
NUMBER_OF_RESULTS=$( jq '.runs[0].results | length' scan-build-report.sarif )
9191
if [ $NUMBER_OF_RESULTS -eq 0 ]; then
9292
echo "$EMPTY_SARIF" > scan-build-report.sarif
@@ -124,4 +124,4 @@ jobs:
124124
make > /dev/null
125125
- name: Run tests
126126
run: |
127-
tests/runtests.sh CHECK_WITH_STDERR=1
127+
tests/runtests.sh VERBOSE=1

.github/workflows/coverage.yml

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,7 @@ jobs:
4747
env:
4848
CHERE_INVOKING: 1
4949
run: |
50-
tests/runtests.sh CHECK_WITH_STDERR=1
50+
tests/runtests.sh VERBOSE=1
5151
- name: Generate coverage data
5252
shell: bash --login -e -o pipefail -o igncr {0}
5353
working-directory: ${{ github.workspace }}
@@ -95,7 +95,7 @@ jobs:
9595
make > /dev/null
9696
- name: Run tests
9797
run: |
98-
make check CHECK_WITH_STDERR=1 SKIP_TOOLS_END_TO_END_TESTS=1
98+
make check SKIP_TOOLS_END_TO_END_TESTS=1 VERBOSE=1
9999
- name: Generate coverage data
100100
run: |
101101
for DIRECTORY in `find . -maxdepth 1 -type d`; do \
@@ -115,6 +115,8 @@ jobs:
115115
- configure_options: '--enable-code-coverage --enable-wide-character-type --enable-winapi'
116116
codecov_name: 'mingw-w64-gcc-no-optimization'
117117
steps:
118+
- name: Configure git
119+
run: git config --global core.autocrlf false
118120
- uses: actions/checkout@v6
119121
- name: Set up MSYS2 with MinGW-w64
120122
uses: msys2/setup-msys2@v2
@@ -138,7 +140,7 @@ jobs:
138140
- name: Run tests
139141
shell: msys2 {0}
140142
run: |
141-
tests/runtests.sh CHECK_WITH_STDERR=1
143+
tests/runtests.sh VERBOSE=1
142144
- name: Generate coverage data
143145
shell: msys2 {0}
144146
run: |

.gitignore

Lines changed: 12 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# Files to ignore by git
22
#
3-
# Version: 20251129
3+
# Version: 20260604
44

55
# Generic auto-generated build files
66
*~
@@ -132,9 +132,20 @@ stamp-h[1-9]
132132
/vshadowtools/vshadowdebug
133133
/vshadowtools/vshadowinfo
134134
/vshadowtools/vshadowmount
135+
/tests/*.dir
135136
/tests/*.exe
137+
/tests/*.log
138+
/tests/*.tmp
139+
/tests/atconfig
140+
/tests/atlocal
136141
/tests/input
137142
/tests/notify_stream.log
143+
/tests/package.m4
144+
/tests/test_inputs_*.at
145+
/tests/test_library
146+
/tests/test_manpages
147+
/tests/test_python_module
148+
/tests/test_tools
138149
/tests/tmp*
139150
/tests/vshadow_test_block
140151
/tests/vshadow_test_block_descriptor

Makefile.am

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -75,6 +75,9 @@ pkgconfigdir = $(libdir)/pkgconfig
7575
pkgconfig_DATA = \
7676
libvshadow.pc
7777

78+
check-build: all
79+
cd $(srcdir)/tests && $(MAKE) check-build $(AM_MAKEFLAGS)
80+
7881
libtool: @LIBTOOL_DEPS@
7982
cd $(srcdir) && $(SHELL) ./config.status --recheck
8083

common/config_winapi.h

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,9 @@
3636

3737
/* Define to the address where bug reports for this package should be sent.
3838
*/
39-
#define PACKAGE_BUGREPORT "joachim.metz@gmail.com"
39+
#if !defined( PACKAGE_BUGREPORT )
40+
#define PACKAGE_BUGREPORT "https://github.com/libyal/libvshadow/issues"
41+
#endif
4042

4143
/* Define the size of the integer for WINAPI
4244
*/

configure.ac

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,8 @@ AC_PREREQ([2.71])
22

33
AC_INIT(
44
[libvshadow],
5-
[20260609],
6-
[joachim.metz@gmail.com])
5+
[20260614],
6+
[https://github.com/libyal/libvshadow/issues])
77

88
AC_CONFIG_SRCDIR(
99
[include/libvshadow.h.in])
@@ -13,6 +13,8 @@ AM_EXTRA_RECURSIVE_TARGETS([sources splint])
1313

1414
AC_CONFIG_MACRO_DIR([m4])
1515

16+
AC_CONFIG_TESTDIR([tests])
17+
1618
dnl Check for host type
1719
AC_CANONICAL_HOST
1820

@@ -209,6 +211,8 @@ AC_CONFIG_FILES([libvshadow/libvshadow.rc])
209211
AC_CONFIG_FILES([libvshadow.pc])
210212
AC_CONFIG_FILES([libvshadow.spec])
211213
AC_CONFIG_FILES([pyproject.toml])
214+
dnl Generate test configuration files
215+
AC_CONFIG_FILES([tests/atlocal])
212216
dnl Generate a source configuration file
213217
AC_CONFIG_HEADERS([common/config.h])
214218

0 commit comments

Comments
 (0)