zeek/testing/btest/scripts/base
Christian Kreibich 3d87400f1d Fix race condition in scripts.base.utils.dir test
The sequence of

- adding a new file
- deleting an existing one
- waiting for Zeek to notice the addition
- re-adding the pre-existing file

was prone to a race: it could happen that Zeek's directory observation would see
the new file in one round, and by the time the next round happens the removal
and re-addition had already happened, thus missing the change and failing the
test.

This avoids the race by placing the removal of the existing file before the
addition of the new one, ensuring that when Zeek notices the addition (and
pushes the test to the next round), it has also seen the removal, so the
re-addition cannot get lost.
2022-07-11 16:26:45 -07:00
..
files Add ability to check if hostname is valid for a specific cert 2021-06-29 15:00:48 +01:00
frameworks sqlite default-logdir test: Remove ls ./logs baseline 2022-07-06 22:57:14 +02:00
misc Add scripts.base.misc.installation btest 2022-05-23 14:16:59 -07:00
protocols Merge remote-tracking branch 'origin/topic/johanna/2198' 2022-07-05 15:09:34 +01:00
utils Fix race condition in scripts.base.utils.dir test 2022-07-11 16:26:45 -07:00