Fix a few places in our unit tests where we were using the system ndctl
instead of the locally built one.  On my system this was leading to false
positive test failures because my local ndctl didn't support this new
command:

  ndctl check-namespace --rewrite-log --repair --force --verbose $dev

Signed-off-by: Ross Zwisler <[email protected]>
---
 test/btt-errors.sh     | 4 ++--
 test/btt-pad-compat.sh | 8 ++++----
 2 files changed, 6 insertions(+), 6 deletions(-)

diff --git a/test/btt-errors.sh b/test/btt-errors.sh
index 68e3652..383abb6 100755
--- a/test/btt-errors.sh
+++ b/test/btt-errors.sh
@@ -47,9 +47,9 @@ force_raw()
 {
        raw="$1"
        if grep -q "$MNT" /proc/mounts; then umount $MNT; fi
-       ndctl disable-namespace "$dev"
+       $NDCTL disable-namespace "$dev"
        echo "$raw" > "/sys/bus/nd/devices/$dev/force_raw"
-       ndctl enable-namespace "$dev"
+       $NDCTL enable-namespace "$dev"
        echo "Set $dev to raw mode: $raw"
        if [[ "$raw" == "1" ]]; then
                raw_bdev=${blockdev%s}
diff --git a/test/btt-pad-compat.sh b/test/btt-pad-compat.sh
index faa773c..618e802 100755
--- a/test/btt-pad-compat.sh
+++ b/test/btt-pad-compat.sh
@@ -112,9 +112,9 @@ cycle_ns()
 force_raw()
 {
        raw="$1"
-       ndctl disable-namespace "$dev"
+       $ndctl disable-namespace "$dev"
        echo "$raw" > "/sys/bus/nd/devices/$dev/force_raw"
-       ndctl enable-namespace "$dev"
+       $ndctl enable-namespace "$dev"
        echo "Set $dev to raw mode: $raw"
        if [[ "$raw" == "1" ]]; then
                raw_bdev=${blockdev%s}
@@ -187,13 +187,13 @@ do_tests()
        verify_idx 0 2
 
        # rewrite log using ndctl, verify conversion to new format
-       ndctl check-namespace --rewrite-log --repair --force --verbose $dev
+       $ndctl check-namespace --rewrite-log --repair --force --verbose $dev
        do_random_io "/dev/$blockdev"
        cycle_ns "$dev"
        verify_idx 0 1
 
        # check-namespace again to make sure everything is ok
-       ndctl check-namespace --force --verbose $dev
+       $ndctl check-namespace --force --verbose $dev
 
        # the old format btt metadata was created with a null parent uuid,
        # making it 'stickier' than a normally created btt. Be sure to clean
-- 
2.14.3

_______________________________________________
Linux-nvdimm mailing list
[email protected]
https://lists.01.org/mailman/listinfo/linux-nvdimm

Reply via email to