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

Re: [RFC PATCH v2] test-lib: drop comment about test_description

From
Junio C Hamano <gitster@pobox.com>
Date
Feb 25, 2023, 22:50 UTC
Message-ID
<xmqq5ybpuzq7.fsf@gitster.g>
In-Reply-To
<20230225190526.21780-1-rybak.a.v@gmail.com>
Andrei Rybak <rybak.a.v@gmail.com> writes:
> ...  The assignment
> of "test_description" and the process of writing tests in general are
> described in detail in "t/README".  So drop the obsolete comment.
Sounds sensible.
> An alternative solution is to move the comment down to the usage of
> variable "test_description".

Or at the beginning, as the comment is about "how you can use this test-lib.sh test library in your tests".

I have no strong preference. Just dropping it sounds easier, as a more readable description already exists elsewhere.

Show 20 quoted lines
>  t/test-lib.sh | 6 ------
>  1 file changed, 6 deletions(-)
>
> diff --git a/t/test-lib.sh b/t/test-lib.sh
> index d272cca008..62136caee5 100644
> --- a/t/test-lib.sh
> +++ b/t/test-lib.sh
> @@ -645,12 +645,6 @@ u200c=$(printf '\342\200\214')
>  
>  export _x05 _x35 LF u200c EMPTY_TREE EMPTY_BLOB ZERO_OID OID_REGEX
>  
> -# Each test should start with something like this, after copyright notices:
> -#
> -# test_description='Description of this test...
> -# This test checks if command xyzzy does the right thing...
> -# '
> -# . ./test-lib.sh
>  test "x$TERM" != "xdumb" && (
>  		test -t 1 &&
>  		tput bold >/dev/null 2>&1 &&
Previous: Andrei RybakNext: Andrei Rybak
Message 3 of 4 in “test-lib: move comment about test_description”
  1. test-lib: move comment about test_descriptionAndrei Rybak, Feb 21, 2023
  2. test-lib: drop comment about test_descriptionAndrei Rybak, Feb 25, 2023
  3. Junio C HamanoFeb 25, 2023
  4. test-lib: drop comment about test_descriptionAndrei Rybak, Feb 26, 2023

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.