git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: [PATCH v2 2/2] tests: add a special setup where rebase.useBuiltin is off

From
Johannes Schindelin <johannes.schindelin@gmx.de>
Date
Nov 14, 2018, 13:53 UTC
Message-ID
<nycvar.QRO.7.76.6.1811141452520.39@tvgsbejvaqbjf.bet>
In-Reply-To
<20181114091506.1452-3-avarab@gmail.com>
Hi Ævar,
On Wed, 14 Nov 2018, Ævar Arnfjörð Bjarmason wrote:
Show 10 quoted lines
> 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 <avarab@gmail.com>
> ---
>  builtin/rebase.c | 5 ++++-
>  t/README         | 4 ++++
>  2 files changed, 8 insertions(+), 1 deletion(-)

I am slightly surprised not to see any ci/ change in this diffstat. Did you mean to add a test axis for Travis, or not?

Ciao, Dscho

Show 36 quoted lines
> 
> 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);
> diff --git a/t/README b/t/README
> index 242497455f..3df5d12e46 100644
> --- a/t/README
> +++ b/t/README
> @@ -339,6 +339,10 @@ for the index version specified.  Can be set to any valid version
>  GIT_TEST_PRELOAD_INDEX=<boolean> exercises the preload-index code path
>  by overriding the minimum number of cache entries required per thread.
>  
> +GIT_TEST_REBASE_USE_BUILTIN=<boolean>, when false, disables the
> +builtin version of git-rebase. See 'rebase.useBuiltin' in
> +git-config(1).
> +
>  GIT_TEST_INDEX_THREADS=<n> enables exercising the multi-threaded loading
>  of the index for the whole test suite by bypassing the default number of
>  cache entries and thread minimums. Setting this to 1 will make the
> -- 
> 2.19.1.1182.g4ecb1133ce
> 
> 
Previous: Ævar Arnfjörð BjarmasonNext: Ævar Arnfjörð Bjarmason
Message 8 of 9 in “rebase.useBuiltin doc & test mode”
  1. 0/2 rebase.useBuiltin doc & test modeÆvar Arnfjörð Bjarmason, Nov 14, 2018
  2. 1/2 rebase doc: document rebase.useBuiltinÆvar Arnfjörð Bjarmason, Nov 14, 2018
  3. Johannes SchindelinNov 14, 2018
  4. Junio C HamanoNov 16, 2018
  5. Johannes SchindelinNov 16, 2018
  6. Junio C HamanoNov 16, 2018
  7. 2/2 tests: add a special setup where rebase.useBuiltin is offÆvar Arnfjörð Bjarmason, Nov 14, 2018
  8. Johannes SchindelinNov 14, 2018
  9. Ævar Arnfjörð BjarmasonNov 14, 2018

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.