Code

Merge branch 'jk/maint-do-not-feed-stdin-to-tests'
[git.git] / t / test-lib.sh
index 0e932dd9758f71cbc95c6ab20f7c11e9056d7826..a65dfc7ea93b3ec95e6ab7cd5b758029fe599d22 100644 (file)
@@ -192,6 +192,7 @@ then
 fi
 
 exec 5>&1
+exec 6<&0
 if test "$verbose" = "t"
 then
        exec 4>&2 3>&1
@@ -475,7 +476,7 @@ test_debug () {
 test_eval_ () {
        # This is a separate function because some tests use
        # "return" to end a test_expect_success block early.
-       eval >&3 2>&4 "$*"
+       eval </dev/null >&3 2>&4 "$*"
 }
 
 test_run_ () {