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

Re: [PATCH v3 3/6] tests: prepare for a world without whatchanged

From
Elijah Newren <newren@gmail.com>
Date
May 12, 2025, 17:36 UTC
Message-ID
<CABPp-BHWjspvWWXpv9ZYmbNzWBHe+w8nxDrpT-nebpZBYT_wSA@mail.gmail.com>
In-Reply-To
<20250503005814.3030099-4-gitster@pobox.com>
On Fri, May 2, 2025 at 5:58 PM Junio C Hamano <gitster@pobox.com> wrote:
Show 5 quoted lines
>
> Some tests on fast-import run "git whatchanged" without even
> checking the output from the command.  It is tempting to remove the
> calls altogether since they are not doing anything useful, but they
> presumably were placed while the tests were developped to manually

Perhaps use "invoked" (or "used" or "employed") rather than "placed"? "placed" feels a bit awkward here.

(and there's the developped typo that Patrick already pointed out.)
Show 7 quoted lines
> sanity check which paths were touched.
>
> Replace these calls with "git log --raw", which is a rough
> equivalent in the more modern Git.
>
> This does not remove "git whatchanged", but we no longer have to
> worry about adjusting these places when we eventually do.
Seems like a definite positive change.
Show 79 quoted lines
> Signed-off-by: Junio C Hamano <gitster@pobox.com>
> ---
>  t/t9300-fast-import.sh       | 12 ++++++------
>  t/t9301-fast-import-notes.sh |  2 +-
>  2 files changed, 7 insertions(+), 7 deletions(-)
>
> diff --git a/t/t9300-fast-import.sh b/t/t9300-fast-import.sh
> index b258dbf1df..4dc3d645bf 100755
> --- a/t/t9300-fast-import.sh
> +++ b/t/t9300-fast-import.sh
> @@ -120,7 +120,7 @@ test_expect_success 'A: create pack from stdin' '
>
>         INPUT_END
>         git fast-import --export-marks=marks.out <input &&
> -       git whatchanged main
> +       git log --raw main
>  '
>
>  test_expect_success 'A: verify pack' '
> @@ -279,7 +279,7 @@ test_expect_success 'A: verify marks import does not crash' '
>         INPUT_END
>
>         git fast-import --import-marks=marks.out <input &&
> -       git whatchanged verify--import-marks
> +       git log --raw verify--import-marks
>  '
>
>  test_expect_success 'A: verify pack' '
> @@ -652,7 +652,7 @@ test_expect_success 'C: incremental import create pack from stdin' '
>         INPUT_END
>
>         git fast-import <input &&
> -       git whatchanged branch
> +       git log --raw branch
>  '
>
>  test_expect_success 'C: verify pack' '
> @@ -715,7 +715,7 @@ test_expect_success 'D: inline data in commit' '
>         INPUT_END
>
>         git fast-import <input &&
> -       git whatchanged branch
> +       git log --raw branch
>  '
>
>  test_expect_success 'D: verify pack' '
> @@ -882,7 +882,7 @@ test_expect_success 'H: deletall, add 1' '
>
>         INPUT_END
>         git fast-import <input &&
> -       git whatchanged H
> +       git log --raw H
>  '
>
>  test_expect_success 'H: verify pack' '
> @@ -2066,7 +2066,7 @@ test_expect_success 'Q: commit notes' '
>         INPUT_END
>
>         git fast-import <input &&
> -       git whatchanged notes-test
> +       git log --raw notes-test
>  '
>
>  test_expect_success 'Q: verify pack' '
> diff --git a/t/t9301-fast-import-notes.sh b/t/t9301-fast-import-notes.sh
> index 1ae4d7c0d3..e62173cf1f 100755
> --- a/t/t9301-fast-import-notes.sh
> +++ b/t/t9301-fast-import-notes.sh
> @@ -76,7 +76,7 @@ INPUT_END
>  test_expect_success 'set up main branch' '
>
>         git fast-import <input &&
> -       git whatchanged main
> +       git log --raw main
>  '
>
>  commit4=$(git rev-parse refs/heads/main)
> --
> 2.49.0-601-ga5925c3955
Looks good.
Previous: Patrick SteinhardtNext: Junio C Hamano
Message 20 of 39 in “Nominating "whatchanged" for removal”
  1. 0/2 Nominating "whatchanged" for removalJunio C Hamano, May 1, 2025
  2. 1/2 you-still-use-that??: help deprecating commands for removalJunio C Hamano, May 1, 2025
  3. 2/2 whatchanged: require --i-still-use-thisJunio C Hamano, May 1, 2025
  4. Junio C HamanoMay 1, 2025
  5. 0/2 Nominating "whatchanged" for removalJunio C Hamano, May 1, 2025
  6. 1/2 you-still-use-that??: help deprecating commands for removalJunio C Hamano, May 1, 2025
  7. 2/2 whatchanged: require --i-still-use-thisJunio C Hamano, May 1, 2025
  8. Patrick SteinhardtMay 2, 2025
  9. Junio C HamanoMay 2, 2025
  10. Patrick SteinhardtMay 5, 2025
  11. Patrick SteinhardtMay 2, 2025
  12. Junio C HamanoMay 2, 2025
  13. 0/6 Nominating "whatchanged" for removalJunio C Hamano, May 3, 2025
  14. 1/6 you-still-use-that??: help deprecating commands for removalJunio C Hamano, May 3, 2025
  15. Elijah NewrenMay 12, 2025
  16. 2/6 doc: prepare for a world without whatchangedJunio C Hamano, May 3, 2025
  17. Elijah NewrenMay 12, 2025
  18. 3/6 tests: prepare for a world without whatchangedJunio C Hamano, May 3, 2025
  19. Patrick SteinhardtMay 5, 2025
  20. Elijah NewrenMay 12, 2025
  21. 4/6 whatchanged: require --i-still-use-thisJunio C Hamano, May 3, 2025
  22. Patrick SteinhardtMay 5, 2025
  23. Junio C HamanoMay 5, 2025
  24. 5/6 whatchanged: remove when built with WITH_BREAKING_CHANGESJunio C Hamano, May 3, 2025
  25. Patrick SteinhardtMay 5, 2025
  26. Junio C HamanoMay 5, 2025
  27. 6/6 whatschanged: list it in BreakingChanges documentJunio C Hamano, May 3, 2025
  28. Elijah NewrenMay 12, 2025
  29. Junio C HamanoMay 12, 2025
  30. 0/6 Nominating "whatchanged" for removalJunio C Hamano, May 12, 2025
  31. 1/6 you-still-use-that??: help deprecating commands for removalJunio C Hamano, May 12, 2025
  32. 2/6 doc: prepare for a world without whatchangedJunio C Hamano, May 12, 2025
  33. 3/6 tests: prepare for a world without whatchangedJunio C Hamano, May 12, 2025
  34. 4/6 whatchanged: require --i-still-use-thisJunio C Hamano, May 12, 2025
  35. Junio C HamanoMay 14, 2025
  36. 5/6 whatchanged: remove when built with WITH_BREAKING_CHANGESJunio C Hamano, May 12, 2025
  37. 6/6 whatschanged: list it in BreakingChanges documentJunio C Hamano, May 12, 2025
  38. Elijah NewrenMay 12, 2025
  39. Junio C HamanoMay 12, 2025

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.