Merge branch 'rr/test-chaining'
authorJunio C Hamano <gitster@pobox.com>
Tue, 20 Dec 2011 00:05:25 +0000 (16:05 -0800)
committerJunio C Hamano <gitster@pobox.com>
Tue, 20 Dec 2011 00:05:25 +0000 (16:05 -0800)
* rr/test-chaining:
t3401: use test_commit in setup
t3401: modernize style
t3040 (subprojects-basic): fix '&&' chaining, modernize style
t1510 (worktree): fix '&&' chaining
t3030 (merge-recursive): use test_expect_code
test: fix '&&' chaining
t3200 (branch): fix '&&' chaining

1  2 
t/t3200-branch.sh
diff --combined t/t3200-branch.sh
index 76903323af37ed1a96b5a11c27eb1e9d63a0e9ef,724ff9de4bf7a747707a0fb77f776588837ff23a..ea82424e471cd53cd08f91c77500412fa192f960
@@@ -22,7 -22,7 +22,7 @@@ test_expect_success 
  
  test_expect_success \
      'git branch --help should not have created a bogus branch' '
-      git branch --help </dev/null >/dev/null 2>/dev/null;
+      test_might_fail git branch --help </dev/null >/dev/null 2>/dev/null &&
       test_path_is_missing .git/refs/heads/--help
  '
  
@@@ -88,7 -88,7 +88,7 @@@ test_expect_success 
  test_expect_success \
      'git branch -m n/n n should work' \
         'git branch -l n/n &&
-         git branch -m n/n n
+       git branch -m n/n n &&
        test_path_is_file .git/logs/refs/heads/n'
  
  test_expect_success 'git branch -m o/o o should fail when o/p exists' '
@@@ -115,22 -115,6 +115,22 @@@ test_expect_success 'git branch -M baz 
        git branch -M baz bam
  '
  
 +test_expect_success 'git branch -M master should work when master is checked out' '
 +      git checkout master &&
 +      git branch -M master
 +'
 +
 +test_expect_success 'git branch -M master master should work when master is checked out' '
 +      git checkout master &&
 +      git branch -M master master
 +'
 +
 +test_expect_success 'git branch -M master2 master2 should work when master is checked out' '
 +      git checkout master &&
 +      git branch master2 &&
 +      git branch -M master2 master2
 +'
 +
  test_expect_success 'git branch -v -d t should work' '
        git branch t &&
        test_path_is_file .git/refs/heads/t &&