Skip to content

Commit 11294bb

Browse files
committed
Merge branch 'sd/t7003-test-path-is-helpers'
Test updates. * sd/t7003-test-path-is-helpers: t7003: modernize path existence checks using test helpers
2 parents dba8cfa + aaf3cc3 commit 11294bb

1 file changed

Lines changed: 6 additions & 6 deletions

File tree

t/t7003-filter-branch.sh

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -92,8 +92,8 @@ test_expect_success 'rewrite, renaming a specific file' '
9292

9393
test_expect_success 'test that the file was renamed' '
9494
test D = "$(git show HEAD:doh --)" &&
95-
! test -f D.t &&
96-
test -f doh &&
95+
test_path_is_missing D.t &&
96+
test_path_is_file doh &&
9797
test D = "$(cat doh)"
9898
'
9999

@@ -103,10 +103,10 @@ test_expect_success 'rewrite, renaming a specific directory' '
103103

104104
test_expect_success 'test that the directory was renamed' '
105105
test dir/D = "$(git show HEAD:diroh/D.t --)" &&
106-
! test -d dir &&
107-
test -d diroh &&
108-
! test -d diroh/dir &&
109-
test -f diroh/D.t &&
106+
test_path_is_missing dir &&
107+
test_path_is_dir diroh &&
108+
test_path_is_missing diroh/dir &&
109+
test_path_is_file diroh/D.t &&
110110
test dir/D = "$(cat diroh/D.t)"
111111
'
112112

0 commit comments

Comments
 (0)