shithub: scc

Download patch

ref: b25d2025d901c27b3ce5fe7497cb82d6bd4e5415
parent: 0f302f9cf00efa7c79f268cf1df4c71e113e0594
author: Roberto E. Vargas Caballero <k0ga@shike2.com>
date: Wed Feb 21 03:37:41 EST 2018

[tests/ar] Add more tests to test-m

--- a/tests/ar/execute/50-test-m.sh
+++ b/tests/ar/execute/50-test-m.sh
@@ -22,17 +22,49 @@
 EOF
 
 cmp $tmp1 $tmp2
+
 ############################################################################
 #move 1st at the end
 
 cp master.a file.a
 ar -mv -a file3 file.a file1
-at -t file.a > $tmp1
+ar -t file.a > $tmp1
 
 cat <<EOF > $tmp2
 file2
 file3
 file1
+EOF
+
+cmp $tmp1 $tmp2
+
+
+############################################################################
+#move 3rd at the beginning
+
+cp master.a file.a
+ar -mv -i file1 file.a file3
+ar -t file.a > $tmp1
+
+cat <<EOF > $tmp2
+file3
+file1
+file2
+EOF
+
+cmp $tmp1 $tmp2
+
+############################################################################
+#and now, test without parameters
+
+cp master.a file.a
+ar -mv file.a
+ar -t file.a > $tmp1
+
+cat <<EOF > $tmp2
+file1
+file2
+file3
 EOF
 
 cmp $tmp1 $tmp2