From: "Alexandr Miloslavskiy via GitGitGadget" <gitgitgadget@gmail.com>
To: git@vger.kernel.org
Cc: Jonathan Nieder <jrnieder@gmail.com>,
Eric Sunshine <sunshine@sunshineco.com>,
Alexandr Miloslavskiy <alexandr.miloslavskiy@syntevo.com>,
Junio C Hamano <gitster@pobox.com>
Subject: [PATCH v4 0/3] t: rework tests for --pathspec-from-file
Date: Tue, 31 Dec 2019 10:15:10 +0000 [thread overview]
Message-ID: <pull.503.v4.git.1577787313.gitgitgadget@gmail.com> (raw)
In-Reply-To: <pull.503.v3.git.1577786032.gitgitgadget@gmail.com>
Please refer to commit messages for rationale.
This branch is a follow-up for [1] where part of branch was merged into `master` via [2].
Previously in [3] there were some concerns on whether removing
copy&pasted tests is good. I still think that yes, it 's a good thing,
mostly because of high volume of potential 13*6=78 duplicate tests.
Still, I separated this change as last patch, so that the remaining
part of the branch can be taken without it.
[1] https://lore.kernel.org/git/pull.490.git.1576161385.gitgitgadget@gmail.com/
[2] https://public-inbox.org/git/pull.445.v4.git.1575381738.gitgitgadget@gmail.com/
[3] https://lore.kernel.org/git/xmqqwoatcn5u.fsf@gitster-ct.c.googlers.com/
Changes since V1
----------------
Small code formatting changes suggested in V1.
Changes since V2
----------------
Changed \\\\ escaping to use here-doc instead.
Changes since V3
----------------
Slightly improved commit message.
Alexandr Miloslavskiy (3):
t: fix quotes tests for --pathspec-from-file
t: directly test parse_pathspec_file()
t: drop copy&pasted tests for --pathspec-from-file
Makefile | 1 +
t/helper/test-parse-pathspec-file.c | 33 +++++++++
t/helper/test-tool.c | 1 +
t/helper/test-tool.h | 1 +
t/t0067-parse_pathspec_file.sh | 108 ++++++++++++++++++++++++++++
t/t2026-checkout-pathspec-file.sh | 70 +-----------------
t/t2072-restore-pathspec-file.sh | 70 +-----------------
t/t3704-add-pathspec-file.sh | 70 +-----------------
t/t7107-reset-pathspec-file.sh | 79 +++-----------------
t/t7526-commit-pathspec-file.sh | 70 +-----------------
10 files changed, 160 insertions(+), 343 deletions(-)
create mode 100644 t/helper/test-parse-pathspec-file.c
create mode 100755 t/t0067-parse_pathspec_file.sh
base-commit: 0a76bd7381ec0dbb7c43776eb6d1ac906bca29e6
Published-As: https://github.com/gitgitgadget/git/releases/tag/pr-503%2FSyntevoAlex%2F%230207(git)_2b_test_parse_directly-v4
Fetch-It-Via: git fetch https://github.com/gitgitgadget/git pr-503/SyntevoAlex/#0207(git)_2b_test_parse_directly-v4
Pull-Request: https://github.com/gitgitgadget/git/pull/503
Range-diff vs v3:
1: 88790669ce = 1: ce0c592bb4 t: fix quotes tests for --pathspec-from-file
2: 68925c2712 = 2: 8748f3baf1 t: directly test parse_pathspec_file()
3: f71021b0dd ! 3: d02a1eac0b t: drop copy&pasted tests for --pathspec-from-file
@@ -3,9 +3,9 @@
t: drop copy&pasted tests for --pathspec-from-file
With direct tests for `parse_pathspec_file()` already in place, it is
- not very reasonable to copy&paste 6 tests for `parse_pathspec_file()`
- for every git command that uses it (I counted 13 commands that could use
- it eventually).
+ not very reasonable to copy&paste 6 similar indirect tests for every git
+ command that uses `parse_pathspec_file()`. I counted 13 potential git
+ commands, which could eventually lead to 6*13=78 duplicate tests.
I believe that indirect tests are redundant because I don't expect
direct tests to ever disagree with indirect tests.
--
gitgitgadget
next prev parent reply other threads:[~2019-12-31 10:15 UTC|newest]
Thread overview: 26+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-12-30 17:42 [PATCH 0/3] t: rework tests for --pathspec-from-file Alexandr Miloslavskiy via GitGitGadget
2019-12-30 17:42 ` [PATCH 1/3] t: fix quotes " Alexandr Miloslavskiy via GitGitGadget
2019-12-30 17:42 ` [PATCH 2/3] t: directly test parse_pathspec_file() Alexandr Miloslavskiy via GitGitGadget
2019-12-30 18:52 ` Junio C Hamano
2019-12-30 19:16 ` Alexandr Miloslavskiy
2019-12-30 17:42 ` [PATCH 3/3] t: drop copy&pasted tests for --pathspec-from-file Alexandr Miloslavskiy via GitGitGadget
2019-12-30 19:15 ` [PATCH v2 0/3] t: rework " Alexandr Miloslavskiy via GitGitGadget
2019-12-30 19:15 ` [PATCH v2 1/3] t: fix quotes " Alexandr Miloslavskiy via GitGitGadget
2019-12-30 21:55 ` Eric Sunshine
2019-12-31 0:26 ` Jonathan Nieder
2019-12-31 10:01 ` Alexandr Miloslavskiy
2019-12-30 19:15 ` [PATCH v2 2/3] t: directly test parse_pathspec_file() Alexandr Miloslavskiy via GitGitGadget
2019-12-30 19:15 ` [PATCH v2 3/3] t: drop copy&pasted tests for --pathspec-from-file Alexandr Miloslavskiy via GitGitGadget
2019-12-31 9:53 ` [PATCH v3 0/3] t: rework " Alexandr Miloslavskiy via GitGitGadget
2019-12-31 9:53 ` [PATCH v3 1/3] t: fix quotes " Alexandr Miloslavskiy via GitGitGadget
2019-12-31 9:53 ` [PATCH v3 2/3] t: directly test parse_pathspec_file() Alexandr Miloslavskiy via GitGitGadget
2019-12-31 9:53 ` [PATCH v3 3/3] t: drop copy&pasted tests for --pathspec-from-file Alexandr Miloslavskiy via GitGitGadget
2019-12-31 10:15 ` Alexandr Miloslavskiy via GitGitGadget [this message]
2019-12-31 10:15 ` [PATCH v4 1/3] t: fix quotes " Alexandr Miloslavskiy via GitGitGadget
2019-12-31 10:15 ` [PATCH v4 2/3] t: directly test parse_pathspec_file() Alexandr Miloslavskiy via GitGitGadget
2019-12-31 10:15 ` [PATCH v4 3/3] t: drop copy&pasted tests for --pathspec-from-file Alexandr Miloslavskiy via GitGitGadget
2020-01-07 21:13 ` [PATCH v4 0/3] t: rework " Junio C Hamano
2020-01-08 15:32 ` Alexandr Miloslavskiy
2020-01-08 17:26 ` Junio C Hamano
2020-01-08 17:42 ` Alexandr Miloslavskiy
2020-01-08 18:50 ` Junio C Hamano
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=pull.503.v4.git.1577787313.gitgitgadget@gmail.com \
--to=gitgitgadget@gmail.com \
--cc=alexandr.miloslavskiy@syntevo.com \
--cc=git@vger.kernel.org \
--cc=gitster@pobox.com \
--cc=jrnieder@gmail.com \
--cc=sunshine@sunshineco.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).