tests/util/grub-fs-tester: Add missing redirect to /dev/null
PATCH 1/1 tests/util/grub-fs-tester: Add missing redirect to /dev/null
In filesystem timestamp test, a check is done to verify that the timestamp for a file as reported in Linux by the filesystem is within a few seconds of the timestamp as reported by GRUB. This is done by grepping the output of GRUB's ls command for the timestamp as reported by the filesystem in Linux and for each of 3 seconds past that timestamp. All of these checks except one redirect the output of grep to /dev/null. Fix this exception to behave as the other checks.
--- tests/util/grub-fs-tester.in | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
tests/util/grub-fs-tester.in +1 -1
@@ -1465,7 +1465,7 @@ for LOGSECSIZE in $(range "$MINLOGSECSIZE" "$MAXLOGSECSIZE" 1); do FSTIMEM2="$(date -d "$FSTIME UTC -2 second" -u "+%Y-%m-%d %H:%M:%S")" FSTIMEM3="$(date -d "$FSTIME UTC -3 second" -u "+%Y-%m-%d %H:%M:%S")" - if echo "$LSOUT" | grep -F 'Last modification time '"$FSTIME" > /dev/null || echo "$LSOUT" | grep -F 'Last modification time '"$FSTIMEM1" > /dev/null || echo "$LSOUT" | grep -F 'Last modification time '"$FSTIMEM2" || echo "$LSOUT" | grep -F 'Last modification time '"$FSTIMEM3" > /dev/null; then + if echo "$LSOUT" | grep -F 'Last modification time '"$FSTIME" > /dev/null || echo "$LSOUT" | grep -F 'Last modification time '"$FSTIMEM1" > /dev/null || echo "$LSOUT" | grep -F 'Last modification time '"$FSTIMEM2" > /dev/null || echo "$LSOUT" | grep -F 'Last modification time '"$FSTIMEM3" > /dev/null; then : else echo FSTIME FAIL
Signature · 1 line
2.34.1
Quoted 9 lines · Glenn Washburn
In filesystem timestamp test, a check is done to verify that the timestamp for a file as reported in Linux by the filesystem is within a few seconds of the timestamp as reported by GRUB. This is done by grepping the output of GRUB's ls command for the timestamp as reported by the filesystem in Linux and for each of 3 seconds past that timestamp. All of these checks except one redirect the output of grep to
/dev/null. Fix this exception to behave as the other checks.Signed-off-by Glenn Washburn <[email protected]>
Daniel