summaryrefslogtreecommitdiffstats
path: root/tests/functions.sh
diff options
context:
space:
mode:
authorKarel Zak2007-07-20 15:08:54 +0200
committerKarel Zak2007-07-23 15:07:13 +0200
commita2c6354ff7c2f8787d6a3b55631eda661b310026 (patch)
tree6e7264de4e45ab608f4a2a6f73d1619d2f46bf7b /tests/functions.sh
parenttests: add license notices, change from gplv2-only to gplv2-or-later (diff)
downloadkernel-qcow2-util-linux-a2c6354ff7c2f8787d6a3b55631eda661b310026.tar.gz
kernel-qcow2-util-linux-a2c6354ff7c2f8787d6a3b55631eda661b310026.tar.xz
kernel-qcow2-util-linux-a2c6354ff7c2f8787d6a3b55631eda661b310026.zip
tests: use $AWK based on configure results
The hardcoded "gawk" seems like a bad idea. Signed-off-by: Karel Zak <kzak@redhat.com>
Diffstat (limited to 'tests/functions.sh')
-rw-r--r--tests/functions.sh4
1 files changed, 2 insertions, 2 deletions
diff --git a/tests/functions.sh b/tests/functions.sh
index 3b10e1af5..fffd7946e 100644
--- a/tests/functions.sh
+++ b/tests/functions.sh
@@ -60,7 +60,7 @@ function ts_log {
function ts_has_option {
NAME="$1"
ALL="$2"
- echo -n $ALL | sed 's/ //g' | gawk 'BEGIN { FS="="; RS="--" } /('$NAME'$|'$NAME'=)/ { print "yes" }'
+ echo -n $ALL | sed 's/ //g' | $AWK 'BEGIN { FS="="; RS="--" } /('$NAME'$|'$NAME'=)/ { print "yes" }'
}
function ts_init {
@@ -167,7 +167,7 @@ function ts_device_init {
dd if=/dev/zero of="$IMAGE" bs=1M count=5 &> /dev/null
$TS_CMD_LOSETUP -f "$IMAGE" 2>&1 >> $TS_OUTPUT
- DEV=$( $TS_CMD_LOSETUP -a | gawk 'BEGIN {FS=":"} /'$IMAGE_RE'/ { print $1 }' )
+ DEV=$( $TS_CMD_LOSETUP -a | $AWK 'BEGIN {FS=":"} /'$IMAGE_RE'/ { print $1 }' )
if [ -z "$DEV" ]; then
ts_device_deinit $DEV