sort assertion to make it more generic
[gitweb.git] / test.sh
diff --git a/test.sh b/test.sh
index 4e00b536d719dd8dae66d561cd716c0c60622ed7..8283fadaad669bdf4ead0d988abc0f97e0edc1c2 100755 (executable)
--- a/test.sh
+++ b/test.sh
@@ -160,7 +160,7 @@ check_equal "$mainfiles" "$chkm $chkms_sub $chks_sub"
 # changes that were split into their own history.  And 'subdir/sub??' never
 # change, since they were *only* changed in the subtree branch.
 allchanges=$(git log --name-only --pretty=format:'' | sort | fixnl)
-check_equal "$allchanges" "$chkm $chkms $chks $chkms_sub"
+check_equal "$allchanges" "$(echo $chkms $chkm $chks $chkms_sub | multiline | sort | fixnl)"
 
 # make sure the --rejoin commits never make it into subproj
 check_equal "$(git log --pretty=format:'%s' HEAD^2 | grep -i split)" ""
@@ -174,7 +174,6 @@ check_equal "$(git log --pretty=format:'%s%n%b' HEAD^2 | grep 'git-subtree.*:')"
 # commits too aggressively.
 joincommits()
 {
-       echo "hello world"
        commit=
        all=
        while read x y; do
@@ -193,14 +192,14 @@ joincommits()
        done
        echo "$commit $all"
 }
-x=0
+x=
 git log --pretty=format:'commit: %H' | joincommits |
 (      while read commit a b; do
                echo "Verifying commit $commit"
                check_equal "$b" ""
-               x=$(($x + 1))
+               x=1
        done
-       check_equal $x 23
+       check_equal "$x" 1
 ) || exit 1
 
 echo