diff options
author | Timon Reinold <tirei+aerc@agon.one> | 2024-07-19 20:20:20 +0200 |
---|---|---|
committer | Robin Jarry <robin@jarry.cc> | 2024-08-04 17:48:45 +0200 |
commit | a794349a40f13da676928e5793e823bbb6912234 (patch) | |
tree | a3f5e308750913414a13dc6b718bd14a99390b58 /.builds | |
parent | b55db9bbda0aaffae3e59919e3d460ba935d8c22 (diff) | |
download | aerc-a794349a40f13da676928e5793e823bbb6912234.tar.gz |
filters: add calendar test vector
Add a test vector for the builtin "calendar" filter. Use the filter's
current output as expected output.
My aim is mostly just to run the calendar filter during "make tests",
this vector doesn't necessarily cover the most interesting sections of
its code. But at least running the filter once on what could be a
common input (a meeting PUBLISH) and checking that its output matches
what was expected should still be better than testing nothing.
Previously, only compiled filters were tested. Testing the calendar
filter (which is interpreted, not compiled) necessitated two changes:
* Compilation output goes into the project root (filters/test.sh:
"$here/../"), but the source code to interpret is in the filters/
subdirectory (filters/test.sh: "$here"/). The executable to invoke is
thus in a different location.
* .builds/alpine-edge.yml uses $FILTERS_TEST_PREFIX to wrap filters in
valgrind, to check that filters written in e.g C don't leak memory.
But for the calendar filter, that would check that the Awk interpreter
doesn't leak memory, failing the test for at least gawk, mawk and
busybox awk. Thus, a $FILTERS_TEST_BIN_PREFIX variable is introduced,
which only applies to binary filters.
Signed-off-by: Timon Reinold <tirei+aerc@agon.one>
Acked-by: Robin Jarry <robin@jarry.cc>
Diffstat (limited to '.builds')
-rw-r--r-- | .builds/alpine-edge.yml | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/.builds/alpine-edge.yml b/.builds/alpine-edge.yml index f6bc9701..c8dcc6f0 100644 --- a/.builds/alpine-edge.yml +++ b/.builds/alpine-edge.yml @@ -13,7 +13,7 @@ environment: DESTDIR: ./out GOFLAGS: "-tags=notmuch" CC: gcc - FILTERS_TEST_PREFIX: valgrind --leak-check=full --error-exitcode=1 + FILTERS_TEST_BIN_PREFIX: valgrind --leak-check=full --error-exitcode=1 tasks: - validate: | gmake -C aerc validate |