From: Junio C Hamano Date: Thu, 28 Jun 2018 19:53:33 +0000 (-0700) Subject: Merge branch 'jc/clean-after-sanity-tests' X-Git-Tag: v2.19.0-rc0~171 X-Git-Url: https://git.lorimer.id.au/gitweb.git/diff_plain/18404434bf406f6a6f892ed73320c5cf9cc187dd?ds=inline;hp=-c Merge branch 'jc/clean-after-sanity-tests' test cleanup. * jc/clean-after-sanity-tests: tests: clean after SANITY tests --- 18404434bf406f6a6f892ed73320c5cf9cc187dd diff --combined t/t0070-fundamental.sh index 23fbe6434a,60e3de7b7b..7b111a56fd --- a/t/t0070-fundamental.sh +++ b/t/t0070-fundamental.sh @@@ -9,19 -9,19 +9,19 @@@ Verify wrappers and compatibility funct . ./test-lib.sh test_expect_success 'character classes (isspace, isalpha etc.)' ' - test-ctype + test-tool ctype ' test_expect_success 'mktemp to nonexistent directory prints filename' ' - test_must_fail test-mktemp doesnotexist/testXXXXXX 2>err && + test_must_fail test-tool mktemp doesnotexist/testXXXXXX 2>err && grep "doesnotexist/test" err ' test_expect_success POSIXPERM,SANITY 'mktemp to unwritable directory prints filename' ' mkdir cannotwrite && - chmod -w cannotwrite && test_when_finished "chmod +w cannotwrite" && + chmod -w cannotwrite && - test_must_fail test-mktemp cannotwrite/testXXXXXX 2>err && + test_must_fail test-tool mktemp cannotwrite/testXXXXXX 2>err && grep "cannotwrite/test" err ' @@@ -31,7 -31,7 +31,7 @@@ test_expect_success 'git_mkstemps_mode test_expect_success 'check for a bug in the regex routines' ' # if this test fails, re-build git with NO_REGEX=1 - test-regex --bug + test-tool regex --bug ' test_done diff --combined t/t7508-status.sh index 18a40257fb,10b084d890..e1f11293e2 --- a/t/t7508-status.sh +++ b/t/t7508-status.sh @@@ -1099,6 -1099,7 +1099,7 @@@ EO ' test_expect_success POSIXPERM,SANITY 'status succeeds in a read-only repository' ' + test_when_finished "chmod 775 .git" && ( chmod a-w .git && # make dir1/tracked stat-dirty @@@ -1108,9 -1109,6 +1109,6 @@@ # make sure "status" succeeded without writing index out git diff-files | grep dir1/tracked ) - status=$? - chmod 775 .git - (exit $status) ' (cd sm && echo > bar && git add bar && git commit -q -m 'Add bar') && git add sm @@@ -1672,12 -1670,12 +1670,12 @@@ test_expect_success '"Initial commit" s ' test_expect_success '--no-optional-locks prevents index update' ' - test-chmtime =1234567890 .git/index && + test-tool chmtime =1234567890 .git/index && git --no-optional-locks status && - test-chmtime -v +0 .git/index >out && + test-tool chmtime --get .git/index >out && grep ^1234567890 out && git status && - test-chmtime -v +0 .git/index >out && + test-tool chmtime --get .git/index >out && ! grep ^1234567890 out '