From 70a827899c5b326739f40688f355fc20a30dfdd7 Mon Sep 17 00:00:00 2001 From: Tavian Barnes Date: Sun, 23 Jun 2019 10:36:25 -0400 Subject: bftw: Queue individual files in depth-first mode This makes the order be truly depth-first. --- tests.sh | 16 +++++++++++++++- 1 file changed, 15 insertions(+), 1 deletion(-) (limited to 'tests.sh') diff --git a/tests.sh b/tests.sh index af343a1..fd31036 100755 --- a/tests.sh +++ b/tests.sh @@ -304,6 +304,7 @@ bsd_tests=( test_execdir_slash test_execdir_slash_pwd test_execdir_slashes + test_execdir_ulimit test_exit @@ -438,6 +439,7 @@ gnu_tests=( test_execdir_slash test_execdir_slash_pwd test_execdir_slashes + test_execdir_ulimit test_executable @@ -1383,7 +1385,9 @@ function test_execdir() { } function test_execdir_plus() { - bfs_diff basic -execdir "$TESTS/sort-args.sh" '{}' + + if [[ "$BFS" != *"-S dfs"* ]]; then + bfs_diff basic -execdir "$TESTS/sort-args.sh" '{}' + + fi } function test_execdir_substring() { @@ -1413,6 +1417,16 @@ function test_execdir_slashes() { bfs_diff /// -maxdepth 0 -execdir echo '{}' ';' } +function test_execdir_ulimit() { + rm -rf scratch/* + mkdir -p scratch/a/b/c/d/e/f/g/h/i/j/k/l/m/n/o/p/q/r/s/t + mkdir -p scratch/a/b/c/d/e/f/g/h/i/j/0/1/2/3/4/5/6/7/8/9 + + closefrom 4 + ulimit -n 10 + bfs_diff scratch -execdir echo '{}' ';' +} + function test_weird_names() { cd weirdnames bfs_diff '-' '(-' '!-' ',' ')' './(' './!' \( \! -print -o -print \) -- cgit v1.2.3