t: strip options from input file names
authorMischa POSLAWSKY <perl@shiar.org>
Thu, 3 Oct 2019 21:01:58 +0000 (23:01 +0200)
committerMischa POSLAWSKY <perl@shiar.org>
Fri, 4 Oct 2019 02:38:14 +0000 (04:38 +0200)
Ignore everything after underscore in output files, so input files do not
need to match irrelevant test options (source data can remain unchanged
regardless of further test variations).

45 files changed:
t/regress.t
t/t1012-unmarked.in [moved from t/t1012-unmarked_--markers=.in with 100% similarity]
t/t1101-wow_much_length.in [moved from t/t1101-wow_much_length_-l30.in with 100% similarity]
t/t1102-strip_contents.in [moved from t/t1102-strip_contents_-l0.in with 100% similarity]
t/t1103-only_separators.in [moved from t/t1103-only_separators_-l1.in with 100% similarity]
t/t1104-abbreviate_contents.in [moved from t/t1104-abbreviate_contents_-l5.in with 100% similarity]
t/t1105-length_percentage.in [moved from t/t1105-length_percentage_-l50%.in with 100% similarity]
t/t1106-forced_length.in [moved from t/t1106-forced_length_-l-30.in with 100% similarity]
t/t1200-unaligned.in [moved from t/t1200-unaligned_-u.in with 100% similarity]
t/t1201-unchanged.in [moved from t/t1201-unchanged_-uw1.in with 100% similarity]
t/t1202-abbreviate_total.in [moved from t/t1202-abbreviate_total_-ul8.in with 100% similarity]
t/t1300-field_number.in [moved from t/t1300-field_number_-f2.in with 100% similarity]
t/t1301-field_grep.in [moved from t/t1301-field_grep_-ftime=.in with 100% similarity]
t/t1310-currency.in [moved from t/t1310-currency_-f,\K.in with 100% similarity]
t/t1311-currency_zoom.in [new symlink]
t/t1311-currency_zoom_-L6-_-f,([0-9.]{5})_--value-length=6_--minval=1.in [deleted symlink]
t/t1312-currency-crop.in [new symlink]
t/t1312-currency-crop_-f,_--value-length=7_--minval=1.1_--maxval=1.11_-L10-30_-s.in [deleted symlink]
t/t1320-earthquakes.in [moved from t/t1320-earthquakes_-f([.0-9]+)(?=,m).in with 100% similarity]
t/t1330-pokemon.in [moved from t/t1330-pokemon_-f(?<=\().in with 100% similarity]
t/t1401-magnitude.in [moved from t/t1401-magnitude_-H.in with 100% similarity]
t/t1403-precision.in [moved from t/t1403-precision_-H.in with 100% similarity]
t/t1501-end_limit.in [moved from t/t1501-end_limit_-L3.in with 100% similarity]
t/t1502-start_limit.in [moved from t/t1502-start_limit_-L9-.in with 100% similarity]
t/t1503-partial.in [moved from t/t1503-partial_-L1-2.in with 100% similarity]
t/t1601-integer_statistics.in [moved from t/t1601-integer_statistics_-sL0.in with 100% similarity]
t/t1602-float_statistics.in [moved from t/t1602-float_statistics_-sL0.in with 100% similarity]
t/t1801-progress.in [new symlink]
t/t1801-progress_-t-1_-ftime=\K.in [deleted symlink]
t/t1901-technicolor.in [moved from t/t1901-technicolor_-cs_--header.in with 100% similarity]
t/t1912-currency_part.in [new symlink]
t/t1912-currency_part_-f,_--value-length=7_--minval=1.1_--maxval=1.11_-L10-30_-cs.in [deleted symlink]
t/t1920-colorwave_uncolored.in [moved from t/t1920-colorwave_uncolored_-c_--palette=.in with 100% similarity]
t/t1921-colorwave_unicolor.in [new symlink]
t/t1921-colorwave_unicolor_-c_--palette=1.in [deleted symlink]
t/t1922-colorwave_duocolor.in [new symlink]
t/t1922-colorwave_duocolor_-c_--palette=40,0.in [deleted symlink]
t/t1923-colorwave_tricolor.in [new symlink]
t/t1923-colorwave_tricolor_-c_--palette=41,0,42.in [deleted symlink]
t/t1924-colorwave_custom_palette.in [new symlink]
t/t1924-colorwave_custom_palette_-c_--palette=31,41,43,42,32.in [deleted symlink]
t/t1931-colorwave_fire.in [new symlink]
t/t1931-colorwave_fire_-c_--palette=fire.in [deleted symlink]
t/t1932-colorwave_fireworks.in [new symlink]
t/t1932-colorwave_fireworks_-c_--palette=fire256.in [deleted symlink]

index 2293efadcec1c6aacdbb0b97749de257f1b61d9d..6a95a9f54e7bc08ec5a7d4d7ca590c4334f13ca9 100755 (executable)
@@ -30,7 +30,7 @@ for candidate in ${@:-t*.out}
 do
        test_count=$((test_count+1))
        file="${candidate%.out}"
-       input="$file.in"
+       input="${file%%_-*}.in"
        name="$(echo ${file#*-} | tr _ \ )"
 
        set -- barcat
@@ -38,7 +38,7 @@ do
        case "$name" in *\ -*) set -- "$@" -"${name#* -}";; esac
        case "$name" in
                *' |'*) set -- sh -c "\$0 \$1 | ${name#* |}" "$@";;
-               *)      set -- "$1" "$2" $3
+               *)      set -- "$1" $2 $3
        esac
 
        if test -n "$regenerate"
similarity index 100%
rename from t/t1200-unaligned_-u.in
rename to t/t1200-unaligned.in
diff --git a/t/t1311-currency_zoom.in b/t/t1311-currency_zoom.in
new file mode 120000 (symlink)
index 0000000..4c5d532
--- /dev/null
@@ -0,0 +1 @@
+t1310-currency.in
\ No newline at end of file
diff --git a/t/t1311-currency_zoom_-L6-_-f,([0-9.]{5})_--value-length=6_--minval=1.in b/t/t1311-currency_zoom_-L6-_-f,([0-9.]{5})_--value-length=6_--minval=1.in
deleted file mode 120000 (symlink)
index 40e390f..0000000
+++ /dev/null
@@ -1 +0,0 @@
-t1310-currency_-f,\K.in
\ No newline at end of file
diff --git a/t/t1312-currency-crop.in b/t/t1312-currency-crop.in
new file mode 120000 (symlink)
index 0000000..4c5d532
--- /dev/null
@@ -0,0 +1 @@
+t1310-currency.in
\ No newline at end of file
diff --git a/t/t1312-currency-crop_-f,_--value-length=7_--minval=1.1_--maxval=1.11_-L10-30_-s.in b/t/t1312-currency-crop_-f,_--value-length=7_--minval=1.1_--maxval=1.11_-L10-30_-s.in
deleted file mode 120000 (symlink)
index 40e390f..0000000
+++ /dev/null
@@ -1 +0,0 @@
-t1310-currency_-f,\K.in
\ No newline at end of file
similarity index 100%
rename from t/t1401-magnitude_-H.in
rename to t/t1401-magnitude.in
similarity index 100%
rename from t/t1403-precision_-H.in
rename to t/t1403-precision.in
similarity index 100%
rename from t/t1503-partial_-L1-2.in
rename to t/t1503-partial.in
diff --git a/t/t1801-progress.in b/t/t1801-progress.in
new file mode 120000 (symlink)
index 0000000..3968c2e
--- /dev/null
@@ -0,0 +1 @@
+t1301-field_grep.in
\ No newline at end of file
diff --git a/t/t1801-progress_-t-1_-ftime=\K.in b/t/t1801-progress_-t-1_-ftime=\K.in
deleted file mode 120000 (symlink)
index 170f92d..0000000
+++ /dev/null
@@ -1 +0,0 @@
-t1301-field_grep_-ftime=.in
\ No newline at end of file
diff --git a/t/t1912-currency_part.in b/t/t1912-currency_part.in
new file mode 120000 (symlink)
index 0000000..4c5d532
--- /dev/null
@@ -0,0 +1 @@
+t1310-currency.in
\ No newline at end of file
diff --git a/t/t1912-currency_part_-f,_--value-length=7_--minval=1.1_--maxval=1.11_-L10-30_-cs.in b/t/t1912-currency_part_-f,_--value-length=7_--minval=1.1_--maxval=1.11_-L10-30_-cs.in
deleted file mode 120000 (symlink)
index 40e390f..0000000
+++ /dev/null
@@ -1 +0,0 @@
-t1310-currency_-f,\K.in
\ No newline at end of file
diff --git a/t/t1921-colorwave_unicolor.in b/t/t1921-colorwave_unicolor.in
new file mode 120000 (symlink)
index 0000000..e52ee82
--- /dev/null
@@ -0,0 +1 @@
+t1920-colorwave_uncolored.in
\ No newline at end of file
diff --git a/t/t1921-colorwave_unicolor_-c_--palette=1.in b/t/t1921-colorwave_unicolor_-c_--palette=1.in
deleted file mode 120000 (symlink)
index 5ecaf32..0000000
+++ /dev/null
@@ -1 +0,0 @@
-t1920-colorwave_uncolored_-c_--palette=.in
\ No newline at end of file
diff --git a/t/t1922-colorwave_duocolor.in b/t/t1922-colorwave_duocolor.in
new file mode 120000 (symlink)
index 0000000..e52ee82
--- /dev/null
@@ -0,0 +1 @@
+t1920-colorwave_uncolored.in
\ No newline at end of file
diff --git a/t/t1922-colorwave_duocolor_-c_--palette=40,0.in b/t/t1922-colorwave_duocolor_-c_--palette=40,0.in
deleted file mode 120000 (symlink)
index 5ecaf32..0000000
+++ /dev/null
@@ -1 +0,0 @@
-t1920-colorwave_uncolored_-c_--palette=.in
\ No newline at end of file
diff --git a/t/t1923-colorwave_tricolor.in b/t/t1923-colorwave_tricolor.in
new file mode 120000 (symlink)
index 0000000..e52ee82
--- /dev/null
@@ -0,0 +1 @@
+t1920-colorwave_uncolored.in
\ No newline at end of file
diff --git a/t/t1923-colorwave_tricolor_-c_--palette=41,0,42.in b/t/t1923-colorwave_tricolor_-c_--palette=41,0,42.in
deleted file mode 120000 (symlink)
index 5ecaf32..0000000
+++ /dev/null
@@ -1 +0,0 @@
-t1920-colorwave_uncolored_-c_--palette=.in
\ No newline at end of file
diff --git a/t/t1924-colorwave_custom_palette.in b/t/t1924-colorwave_custom_palette.in
new file mode 120000 (symlink)
index 0000000..e52ee82
--- /dev/null
@@ -0,0 +1 @@
+t1920-colorwave_uncolored.in
\ No newline at end of file
diff --git a/t/t1924-colorwave_custom_palette_-c_--palette=31,41,43,42,32.in b/t/t1924-colorwave_custom_palette_-c_--palette=31,41,43,42,32.in
deleted file mode 120000 (symlink)
index 5ecaf32..0000000
+++ /dev/null
@@ -1 +0,0 @@
-t1920-colorwave_uncolored_-c_--palette=.in
\ No newline at end of file
diff --git a/t/t1931-colorwave_fire.in b/t/t1931-colorwave_fire.in
new file mode 120000 (symlink)
index 0000000..e52ee82
--- /dev/null
@@ -0,0 +1 @@
+t1920-colorwave_uncolored.in
\ No newline at end of file
diff --git a/t/t1931-colorwave_fire_-c_--palette=fire.in b/t/t1931-colorwave_fire_-c_--palette=fire.in
deleted file mode 120000 (symlink)
index 5ecaf32..0000000
+++ /dev/null
@@ -1 +0,0 @@
-t1920-colorwave_uncolored_-c_--palette=.in
\ No newline at end of file
diff --git a/t/t1932-colorwave_fireworks.in b/t/t1932-colorwave_fireworks.in
new file mode 120000 (symlink)
index 0000000..e52ee82
--- /dev/null
@@ -0,0 +1 @@
+t1920-colorwave_uncolored.in
\ No newline at end of file
diff --git a/t/t1932-colorwave_fireworks_-c_--palette=fire256.in b/t/t1932-colorwave_fireworks_-c_--palette=fire256.in
deleted file mode 120000 (symlink)
index 5ecaf32..0000000
+++ /dev/null
@@ -1 +0,0 @@
-t1920-colorwave_uncolored_-c_--palette=.in
\ No newline at end of file