t: stop using GIT_CONFIG to cross repo boundaries
[gitweb.git] / t / t3200-branch.sh
index 0fe7647928b9d20963e60e56009f72c54ee488e2..d45e95cfec85ec712f1a85a499641b1f5f1595bc 100755 (executable)
@@ -18,7 +18,7 @@ test_expect_success 'prepare a trivial repository' '
 '
 
 test_expect_success 'git branch --help should not have created a bogus branch' '
-       test_might_fail git branch --help </dev/null >/dev/null 2>/dev/null &&
+       test_might_fail git branch --man --help </dev/null >/dev/null 2>&1 &&
        test_path_is_missing .git/refs/heads/--help
 '
 
@@ -849,11 +849,7 @@ test_expect_success 'detect typo in branch name when using --edit-description' '
        write_script editor <<-\EOF &&
                echo "New contents" >"$1"
        EOF
-       (
-               EDITOR=./editor &&
-               export EDITOR &&
-               test_must_fail git branch --edit-description no-such-branch
-       )
+       test_must_fail env EDITOR=./editor git branch --edit-description no-such-branch
 '
 
 test_expect_success 'refuse --edit-description on unborn branch for now' '
@@ -861,11 +857,7 @@ test_expect_success 'refuse --edit-description on unborn branch for now' '
                echo "New contents" >"$1"
        EOF
        git checkout --orphan unborn &&
-       (
-               EDITOR=./editor &&
-               export EDITOR &&
-               test_must_fail git branch --edit-description
-       )
+       test_must_fail env EDITOR=./editor git branch --edit-description
 '
 
 test_expect_success '--merged catches invalid object names' '