summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPádraig Brady <P@draigBrady.com>2012-01-03 19:35:12 +0000
committerPádraig Brady <P@draigBrady.com>2012-01-05 15:13:34 +0000
commit45354d58dea427f050390bbf0f04c6c509a61b0e (patch)
tree73f99cceedc7bd0afd1a48dd9c8301e9ac641800
parent512662fb30c448ee6564050cfe45e6b865c1f435 (diff)
downloadcoreutils-45354d58dea427f050390bbf0f04c6c509a61b0e.tar.gz
tests: avoid ulimit issue on bash 3.2 on OS X
* tests/misc/sort-continue: Perform the glob before the ulimit, as it was seen to make the glob fail on bash 3.2 on Mac OS X 10.6.8 at least.
-rwxr-xr-xtests/misc/sort-continue6
1 files changed, 4 insertions, 2 deletions
diff --git a/tests/misc/sort-continue b/tests/misc/sort-continue
index 9fade43ea..1491dbf65 100755
--- a/tests/misc/sort-continue
+++ b/tests/misc/sort-continue
@@ -27,10 +27,12 @@ for i in $(seq 31); do
echo $i | tee -a in > __test.$i || framework_failure_
done
+# glob before ulimit to avoid issues on bash 3.2 on OS X 10.6.8 at least
+test_files=$(echo __test.*)
(
ulimit -n 6
- sort -n -m __test.* 3<&- 4<&- 5<&- < /dev/null > out
+ sort -n -m $test_files 3<&- 4<&- 5<&- < /dev/null > out
) &&
compare in out ||
{ fail=1; echo 'file descriptor exhaustion not handled' 1>&2; }
@@ -38,7 +40,7 @@ compare in out ||
echo 32 | tee -a in > in1
(
ulimit -n 6
- sort -n -m __test.* - 3<&- 4<&- 5<&- < in1 > out
+ sort -n -m $test_files - 3<&- 4<&- 5<&- < in1 > out
) &&
compare in out || { fail=1; echo 'stdin not handled properly' 1>&2; }