diff options
Diffstat (limited to 't/perf/perf-lib.sh')
-rw-r--r-- | t/perf/perf-lib.sh | 14 |
1 files changed, 9 insertions, 5 deletions
diff --git a/t/perf/perf-lib.sh b/t/perf/perf-lib.sh index 13e389367a..e385c6896f 100644 --- a/t/perf/perf-lib.sh +++ b/t/perf/perf-lib.sh @@ -147,14 +147,16 @@ test_run_perf_ () { "$GTIME" -f "%E %U %S" -o test_time.$i "$SHELL" -c ' . '"$TEST_DIRECTORY"/test-lib-functions.sh' test_export () { - [ $# != 0 ] || return 0 - test_export_="$test_export_\\|$1" - shift - test_export "$@" + test_export_="$test_export_ $*" } '"$1"' ret=$? -set | sed -n "s'"/'/'\\\\''/g"';s/^\\($test_export_\\)/export '"'&'"'/p" >test_vars +needles= +for v in $test_export_ +do + needles="$needles;s/^$v=/export $v=/p" +done +set | sed -n "s'"/'/'\\\\''/g"'$needles" >test_vars exit $ret' >&3 2>&4 eval_ret=$? @@ -245,3 +247,5 @@ test_at_end_hook_ () { test_export () { export "$@" } + +test_lazy_prereq PERF_EXTRA 'test_bool_env GIT_PERF_EXTRA false' |