From 62c23938fae5b7a374388c64fbdf8ee9ecb51b92 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=C3=86var=20Arnfj=C3=B6r=C3=B0=20Bjarmason?= Date: Wed, 14 Nov 2018 09:15:06 +0000 Subject: tests: add a special setup where rebase.useBuiltin is off MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Add a GIT_TEST_REBASE_USE_BUILTIN=false test mode which is equivalent to running with rebase.useBuiltin=false. This is needed to spot that we're not introducing any regressions in the legacy rebase version while we're carrying both it and the new builtin version. Signed-off-by: Ævar Arnfjörð Bjarmason Signed-off-by: Junio C Hamano --- builtin/rebase.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'builtin') diff --git a/builtin/rebase.c b/builtin/rebase.c index 0ee06aa363..68ad8c1149 100644 --- a/builtin/rebase.c +++ b/builtin/rebase.c @@ -48,7 +48,10 @@ static int use_builtin_rebase(void) { struct child_process cp = CHILD_PROCESS_INIT; struct strbuf out = STRBUF_INIT; - int ret; + int ret, env = git_env_bool("GIT_TEST_REBASE_USE_BUILTIN", -1); + + if (env != -1) + return env; argv_array_pushl(&cp.args, "config", "--bool", "rebase.usebuiltin", NULL); -- cgit v1.2.3