summaryrefslogtreecommitdiff
path: root/t
diff options
context:
space:
mode:
Diffstat (limited to 't')
-rw-r--r--t/perf/perf-lib.sh11
-rwxr-xr-xt/perf/run2
2 files changed, 13 insertions, 0 deletions
diff --git a/t/perf/perf-lib.sh b/t/perf/perf-lib.sh
index 9cdccba222..b58a43ea43 100644
--- a/t/perf/perf-lib.sh
+++ b/t/perf/perf-lib.sh
@@ -27,6 +27,17 @@ TEST_NO_MALLOC_CHECK=t
. ../test-lib.sh
+if test -n "$GIT_TEST_INSTALLED" -a -z "$PERF_SET_GIT_TEST_INSTALLED"
+then
+ error "Do not use GIT_TEST_INSTALLED with the perf tests.
+
+Instead use:
+
+ ./run <path-to-git> -- <tests>
+
+See t/perf/README for details."
+fi
+
# Variables from test-lib that are normally internal to the tests; we
# need to export them for test_perf subshells
export TEST_DIRECTORY TRASH_DIRECTORY GIT_BUILD_DIR GIT_TEST_CMP
diff --git a/t/perf/run b/t/perf/run
index cd3882b117..c7b86104e1 100755
--- a/t/perf/run
+++ b/t/perf/run
@@ -84,6 +84,8 @@ set_git_test_installed () {
GIT_TEST_INSTALLED=$mydir_abs
fi
export GIT_TEST_INSTALLED
+ PERF_SET_GIT_TEST_INSTALLED=true
+ export PERF_SET_GIT_TEST_INSTALLED
}
run_dirs_helper () {