mirror of
https://github.com/fish-shell/fish-shell
synced 2025-01-27 20:25:12 +00:00
Fix test output for complete -e
tests
GNU sort behaves stupidly when LC_ALL is not C. This caused the test output to be sorted wrong.
This commit is contained in:
parent
90a4fd34d2
commit
1c4223889b
2 changed files with 8 additions and 2 deletions
|
@ -61,14 +61,14 @@ for i in *.in
|
||||||
else
|
else
|
||||||
set res fail
|
set res fail
|
||||||
echo Output differs for file $i. Diff follows:
|
echo Output differs for file $i. Diff follows:
|
||||||
diff tmp.out $template_out
|
diff -u tmp.out $template_out
|
||||||
end
|
end
|
||||||
|
|
||||||
if diff tmp.err $template_err >/dev/null
|
if diff tmp.err $template_err >/dev/null
|
||||||
else
|
else
|
||||||
set res fail
|
set res fail
|
||||||
echo Error output differs for file $i. Diff follows:
|
echo Error output differs for file $i. Diff follows:
|
||||||
diff tmp.err $template_err
|
diff -u tmp.err $template_err
|
||||||
end
|
end
|
||||||
|
|
||||||
if test (cat tmp.status) = (cat $template_status)
|
if test (cat tmp.status) = (cat $template_status)
|
||||||
|
|
|
@ -17,6 +17,12 @@ complete -C'BBBB -'
|
||||||
# Test that erasing completions works correctly
|
# Test that erasing completions works correctly
|
||||||
echo
|
echo
|
||||||
|
|
||||||
|
function sort
|
||||||
|
# GNU sort is really stupid, a non-C locale seems to make it assume --dictionary-order
|
||||||
|
# If I wanted --dictionary-order, I would have specified --dictionary-order!
|
||||||
|
env LC_ALL=C sort $argv
|
||||||
|
end
|
||||||
|
|
||||||
complete -c CCCC -l bar
|
complete -c CCCC -l bar
|
||||||
complete -c CCCC -l baz
|
complete -c CCCC -l baz
|
||||||
complete -c CCCC -o bar
|
complete -c CCCC -o bar
|
||||||
|
|
Loading…
Reference in a new issue