NeilBrown: test/ddf: don't insist that mdadm. conf is always in the same order.

Martin F. Krafft madduck at alioth.debian.org
Tue Oct 27 19:21:57 UTC 2009


Module: mdadm
Branch: upstream
Commit: 00eb571675b431b3845c67abba891a198cef06f3
URL:    http://git.debian.org/?p=pkg-mdadm/mdadm.git;a=commit;h=00eb571675b431b3845c67abba891a198cef06f3

Author: NeilBrown <neilb at suse.de>
Date:   Mon Oct 19 16:58:38 2009 +1100

test/ddf:  don't insist that mdadm.conf is always in the same order.

When created by different process, the order could reasonably
be different.  So sort before compare

Signed-off-by: NeilBrown <neilb at suse.de>

---

 tests/10ddf-create |    8 ++++----
 1 files changed, 4 insertions(+), 4 deletions(-)

diff --git a/tests/10ddf-create b/tests/10ddf-create
index db22b64..a32dc0f 100644
--- a/tests/10ddf-create
+++ b/tests/10ddf-create
@@ -55,8 +55,8 @@ mdadm -Ss
 mdadm -Asc /var/tmp/mdadm.conf
 check nosync  # This failed once. The raid5 was resyncing.
 
-mdadm -Dbs > /tmp/mdadm.conf
-diff /tmp/mdadm.conf /var/tmp/mdadm.conf
+mdadm -Dbs | sort > /tmp/mdadm.conf
+sort /var/tmp/mdadm.conf | diff /tmp/mdadm.conf -
 mdadm -Ss
 
 # and now assemble fully incrementally.
@@ -70,7 +70,7 @@ do
 done
 check nosync
 
-mdadm -Dbs > /tmp/mdadm.conf
-diff /tmp/mdadm.conf /var/tmp/mdadm.conf
+mdadm -Dbs | sort > /tmp/mdadm.conf
+sort /var/tmp/mdadm.conf | diff /tmp/mdadm.conf -
 mdadm -Ss
 rm /tmp/mdadm.conf /var/tmp/mdadm.conf




More information about the pkg-mdadm-commits mailing list