diff options
author | Junio C Hamano <gitster@pobox.com> | 2011-07-06 15:38:28 -0700 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2011-07-06 15:38:28 -0700 |
commit | 25d33546d474c7c28b72013c262fc23337cb3b21 (patch) | |
tree | 7551eb457a33329be6b3bb0fc11f76118a6e2c42 /t/t1004-read-tree-m-u-wf.sh | |
parent | Merge commit 'v1.7.0' into jc/checkout-reflog-fix (diff) | |
parent | Git 1.7.6 (diff) | |
download | tgif-25d33546d474c7c28b72013c262fc23337cb3b21.tar.xz |
Merge commit 'v1.7.6' into jc/checkout-reflog-fix
* commit 'v1.7.6': (3211 commits)
Git 1.7.6
completion: replace core.abbrevguard to core.abbrev
Git 1.7.6-rc3
Documentation: git diff --check respects core.whitespace
gitweb: 'pickaxe' and 'grep' features requires 'search' to be enabled
t7810: avoid unportable use of "echo"
plug a few coverity-spotted leaks
builtin/gc.c: add missing newline in message
tests: link shell libraries into valgrind directory
t/Makefile: pass test opts to valgrind target properly
sh-i18n--envsubst.c: do not #include getopt.h
Fix typo: existant->existent
Git 1.7.6-rc2
gitweb: do not misparse nonnumeric content tag files that contain a digit
Git 1.7.6-rc1
fetch: do not leak a refspec
t3703: skip more tests using colons in file names on Windows
gitweb: Fix usability of $prevent_xss
gitweb: Move "Requirements" up in gitweb/INSTALL
gitweb: Describe CSSMIN and JSMIN in gitweb/INSTALL
...
Diffstat (limited to 't/t1004-read-tree-m-u-wf.sh')
-rwxr-xr-x | t/t1004-read-tree-m-u-wf.sh | 25 |
1 files changed, 13 insertions, 12 deletions
diff --git a/t/t1004-read-tree-m-u-wf.sh b/t/t1004-read-tree-m-u-wf.sh index f19b4a2a4a..b3ae7d52c6 100755 --- a/t/t1004-read-tree-m-u-wf.sh +++ b/t/t1004-read-tree-m-u-wf.sh @@ -3,6 +3,7 @@ test_description='read-tree -m -u checks working tree files' . ./test-lib.sh +. "$TEST_DIRECTORY"/lib-read-tree.sh # two-tree test @@ -29,7 +30,7 @@ test_expect_success 'two-way not clobbering' ' echo >file2 master creates untracked file2 && echo >subdir/file2 master creates untracked subdir/file2 && - if err=`git read-tree -m -u master side 2>&1` + if err=`read_tree_u_must_succeed -m -u master side 2>&1` then echo should have complained false @@ -42,7 +43,7 @@ echo file2 >.gitignore test_expect_success 'two-way with incorrect --exclude-per-directory (1)' ' - if err=`git read-tree -m --exclude-per-directory=.gitignore master side 2>&1` + if err=`read_tree_u_must_succeed -m --exclude-per-directory=.gitignore master side 2>&1` then echo should have complained false @@ -53,7 +54,7 @@ test_expect_success 'two-way with incorrect --exclude-per-directory (1)' ' test_expect_success 'two-way with incorrect --exclude-per-directory (2)' ' - if err=`git read-tree -m -u --exclude-per-directory=foo --exclude-per-directory=.gitignore master side 2>&1` + if err=`read_tree_u_must_succeed -m -u --exclude-per-directory=foo --exclude-per-directory=.gitignore master side 2>&1` then echo should have complained false @@ -64,7 +65,7 @@ test_expect_success 'two-way with incorrect --exclude-per-directory (2)' ' test_expect_success 'two-way clobbering a ignored file' ' - git read-tree -m -u --exclude-per-directory=.gitignore master side + read_tree_u_must_succeed -m -u --exclude-per-directory=.gitignore master side ' rm -f .gitignore @@ -84,7 +85,7 @@ test_expect_success 'three-way not complaining on an untracked path in both' ' echo >file2 file two is untracked on the master side && echo >subdir/file2 file two is untracked on the master side && - git read-tree -m -u branch-point master side + read_tree_u_must_succeed -m -u branch-point master side ' test_expect_success 'three-way not clobbering a working tree file' ' @@ -94,7 +95,7 @@ test_expect_success 'three-way not clobbering a working tree file' ' git checkout master && echo >file3 file three created in master, untracked && echo >subdir/file3 file three created in master, untracked && - if err=`git read-tree -m -u branch-point master side 2>&1` + if err=`read_tree_u_must_succeed -m -u branch-point master side 2>&1` then echo should have complained false @@ -113,7 +114,7 @@ test_expect_success 'three-way not complaining on an untracked file' ' echo >file3 file three created in master, untracked && echo >subdir/file3 file three created in master, untracked && - git read-tree -m -u --exclude-per-directory=.gitignore branch-point master side + read_tree_u_must_succeed -m -u --exclude-per-directory=.gitignore branch-point master side ' test_expect_success '3-way not overwriting local changes (setup)' ' @@ -137,7 +138,7 @@ test_expect_success '3-way not overwriting local changes (our side)' ' git reset --hard && echo >>file1 "local changes" && - git read-tree -m -u branch-point side-a side-b && + read_tree_u_must_succeed -m -u branch-point side-a side-b && grep "new line to be kept" file1 && grep "local changes" file1 @@ -151,7 +152,7 @@ test_expect_success '3-way not overwriting local changes (their side)' ' git reset --hard && echo >>file2 "local changes" && - test_must_fail git read-tree -m -u branch-point side-a side-b && + read_tree_u_must_fail -m -u branch-point side-a side-b && ! grep "new line to be kept" file2 && grep "local changes" file2 @@ -173,11 +174,11 @@ test_expect_success SYMLINKS 'funny symlink in work tree' ' git add a/b && git commit -m "we add a/b" && - git read-tree -m -u sym-a sym-a sym-b + read_tree_u_must_succeed -m -u sym-a sym-a sym-b ' -test_expect_success SYMLINKS 'funny symlink in work tree, un-unlink-able' ' +test_expect_success SYMLINKS,SANITY 'funny symlink in work tree, un-unlink-able' ' rm -fr a b && git reset --hard && @@ -209,7 +210,7 @@ test_expect_success 'D/F setup' ' test_expect_success 'D/F' ' git checkout side-b && - git read-tree -m -u branch-point side-b side-a && + read_tree_u_must_succeed -m -u branch-point side-b side-a && git ls-files -u >actual && ( a=$(git rev-parse branch-point:subdir/file2) |