Two unrelated tests were using the same path for testing. That's incorrect because if the test that depends on the other test, which creates the directory hierarcy, is ran using the --run flag then it will fail, even though it should pass, because the path doesn't exist. Unrelated tests should not have dependencies among them. Signed-off-by: Plato Kiorpelidis <kioplato@xxxxxxxxx> --- t/t0066-dir-iterator.sh | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/t/t0066-dir-iterator.sh b/t/t0066-dir-iterator.sh index 807c43d447..801749eb7e 100755 --- a/t/t0066-dir-iterator.sh +++ b/t/t0066-dir-iterator.sh @@ -63,9 +63,11 @@ test_expect_success 'begin should fail upon inexistent paths' ' ' test_expect_success 'begin should fail upon non directory paths' ' + >some-file && + echo "dir_iterator_begin failure: ENOTDIR" >expected-non-dir-output && - test_must_fail test-tool dir-iterator ./dir/b >actual-non-dir-output && + test_must_fail test-tool dir-iterator ./some-file >actual-non-dir-output && test_cmp expected-non-dir-output actual-non-dir-output ' -- 2.36.1