[kdbus] sync with kdbus (kdbus.h - commit: 5ae1ecac44cb)
[platform/upstream/glib.git] / tests / run-collate-tests.sh
index 7bd290c..24f3d69 100755 (executable)
@@ -13,7 +13,6 @@ echo_v ()
   fi
 }
 
-LC_COLLATE=en_US
 error_out=/dev/null
 if [ "$1" = "-v" ]; then
   verbose=1
@@ -23,17 +22,17 @@ for I in ${srcdir:-.}/collate/*.in; do
   echo_v "Sorting $I"
   name=`basename $I .in`
   ./unicode-collate $I > collate.out
-  if ! diff collate.out ${srcdir:-.}/collate/$name.unicode; then 
+  if [ $? -eq 2 ]; then
+    exit 0
+  fi   
+  diff collate.out ${srcdir:-.}/collate/$name.unicode || 
     fail "unexpected error when using g_utf8_collate() on $I"
-  fi  
   ./unicode-collate --key $I > collate.out
-  if ! diff collate.out ${srcdir:-.}/collate/$name.unicode; then 
+  diff collate.out ${srcdir:-.}/collate/$name.unicode ||
     fail "unexpected error when using g_utf8_collate_key() on $I"
-  fi  
   ./unicode-collate --file $I > collate.out
-  if ! diff collate.out ${srcdir:-.}/collate/$name.file; then 
+  diff collate.out ${srcdir:-.}/collate/$name.file ||
     fail "unexpected error when using g_utf8_collate_key_for_filename() on $I"
-  fi  
 done
 
 echo_v "All tests passed."