From cfcfadac1d61093f900d1903f580818d244479ad Mon Sep 17 00:00:00 2001 From: Mike Fleetwood Date: Sat, 1 Oct 2016 16:40:17 +0100 Subject: [PATCH 46/53] tests: t3310-flags.sh: Stop excluding certain flags from being tested Also grep for whole words, grep -w, to avoid flag 'boot' being matched as a substring of flag 'legacy_boot'. Signed-off-by: Brian C. Lane --- tests/t3310-flags.sh | 9 ++------- 1 file changed, 2 insertions(+), 7 deletions(-) diff --git a/tests/t3310-flags.sh b/tests/t3310-flags.sh index 85a673a..5cbf2da 100644 --- a/tests/t3310-flags.sh +++ b/tests/t3310-flags.sh @@ -49,15 +49,10 @@ for table_type in msdos gpt; do for mode in on_only on_and_off ; do for flag in $flags; do - - # Exclude the supplemental flags. - # These are not boolean, like the others. - case $flag in boot|lba|hidden) continue;; esac - # Turn on each flag, one at a time. parted -m -s $dev set 1 $flag on unit s print > raw 2> err || fail=1 extract_flags raw > out - grep -F "$flag" out \ + grep -w "$flag" out \ || { warn_ "$ME_: $table_type: flag '$flag' not turned on: $(cat out)"; fail=1; } compare /dev/null err || fail=1 @@ -65,7 +60,7 @@ for table_type in msdos gpt; do # Turn it off parted -m -s $dev set 1 $flag off unit s print > raw 2> err || fail=1 extract_flags raw > out - grep -F "$flag" out \ + grep -w "$flag" out \ && { warn_ "$ME_: $table_type: flag '$flag' not turned off: $(cat out)"; fail=1; } compare /dev/null err || fail=1 fi -- 2.7.4