mbox series

[0/5] Fixes to trailer test script, help text, and documentation

Message ID pull.1564.git.1691210737.gitgitgadget@gmail.com (mailing list archive)
Headers show
Series Fixes to trailer test script, help text, and documentation | expand

Message

Elijah Newren via GitGitGadget Aug. 5, 2023, 4:45 a.m. UTC
This series contains various fixes to the trailer code. They pertain to
fixes to the test script, the command line help text for the
interpret-trailers builtin, and the documentation.

Patch 1 is the biggest one, but also perhaps the most important as it does
cleanups in the tests where we used 'git config' in a test case without
cleaning up that state for the next test. This makes the tests
self-contained, making it easier to add new tests anywhere along the script,
without worrying about previously-set implicit state. These test cleanups
exposed lots of cases where the test cases are mutating more configuration
state than is necessary to test the specific behavior in the test; however
such extraneous configurations were not cleaned up to make these patches
easier to review (again, we are not changing any behavior and we are also
not changing what the test cases themselves purport to do).

Note that Patch 1 was originally a 22-commit series, but was squashed
together to make it easier to see the final diff for each test case. You can
see the 22-commit breakdown at
https://github.com/listx/git/tree/backup-trailer-22-commit-breakdown

Patch 3 adds some tests to check the behavior of '--no-if-exists' and
'--no-if-missing', which weren't previously tested. It also adds
similarly-themed test cases for '--no-where' which only had 1 test case for
it.

The other patches aren't as important, but are included here because I think
they are too small to include in a separate series.

Linus Arver (5):
  trailer tests: make test cases self-contained
  trailer test description: this tests --where=after, not --where=before
  trailer: add tests to check defaulting behavior with --no-* flags
  trailer: trailer location is a place, not an action
  trailer --no-divider help: describe usual "---" meaning

 Documentation/git-interpret-trailers.txt |  14 +-
 builtin/interpret-trailers.c             |   4 +-
 t/t7513-interpret-trailers.sh            | 506 +++++++++++++++++++----
 3 files changed, 443 insertions(+), 81 deletions(-)


base-commit: 1b0a5129563ebe720330fdc8f5c6843d27641137
Published-As: https://github.com/gitgitgadget/git/releases/tag/pr-1564%2Flistx%2Ftrailer-fixes-v1
Fetch-It-Via: git fetch https://github.com/gitgitgadget/git pr-1564/listx/trailer-fixes-v1
Pull-Request: https://github.com/gitgitgadget/git/pull/1564