Add a test to ensure ONCE works even when taking input from STDIN if $OnceFile is set.

This commit is contained in:
Dianne Skoll
2024-07-10 13:55:41 -04:00
parent e3f9380fcd
commit 1d8cb9749e
2 changed files with 16 additions and 0 deletions

View File

@@ -576,6 +576,13 @@ rm -f ../tests/once.timestamp
../src/remind ../tests/test-once.rem >> ../tests/test.out 2>&1
tail +2 ../tests/once.timestamp >> ../tests/test.out 2>&1
rm -f ../tests/once.timestamp
../src/remind - < ../tests/test-once.rem >> ../tests/test.out 2>&1
../src/remind - < ../tests/test-once.rem >> ../tests/test.out 2>&1
../src/remind - < ../tests/test-once.rem >> ../tests/test.out 2>&1
tail +2 ../tests/once.timestamp >> ../tests/test.out 2>&1
rm -f ../tests/once.timestamp
# Remove references to SysInclude, which is build-specific
grep -F -v '$SysInclude' < ../tests/test.out > ../tests/test.out.1 && mv -f ../tests/test.out.1 ../tests/test.out
cmp -s ../tests/test.out ../tests/test.cmp

View File

@@ -12379,3 +12379,12 @@ No reminders.
No reminders.
# This is a timestamp file used by Remind to track ONCE reminders.
# Do not edit or delete it.
-stdin-(7): Not setting $OnceFile: Already processed a reminder with a ONCE clause
This should only be issued once per day.
-stdin-(7): Not setting $OnceFile: Already processed a reminder with a ONCE clause
No reminders.
-stdin-(7): Not setting $OnceFile: Already processed a reminder with a ONCE clause
No reminders.
# This is a timestamp file used by Remind to track ONCE reminders.
# Do not edit or delete it.