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