Re: [RFC PATCH v2 6/6] t/Makefile: run unit tests alongside shell tests
- From
Junio C Hamano <gitster@pobox.com>
- Date
- Feb 7, 2024, 23:26 UTC
- Message-ID
- <xmqqle7vrh3v.fsf@gitster.g>
- In-Reply-To
- <20240207224350.GA537799@coredump.intra.peff.net>
Jeff King <peff@peff.net> writes:
Show 13 quoted lines
> Not if they share the same command-line options. If you use something > like "--state=slow,save", then the first run will write the list of all > tests to ".prove", and then the second will run every test mentioned in > .prove (in addition to the unit-tests provided on the command-line). > > You should be able to work around it by passing "--statefile". I _think_ > it might be OK to just do that unconditionally. Something like: > > prove --exec $(TEST_SHELL_PATH $(GIT_PROVE_OPTS) $(T) :: $(GIT_TEST_OPTS) > prove --statefile=.prove-unit-tests $(GIT_PROVE_OPTS) $(UNIT_TESTS) :: $(GIT_TEST_OPTS) > > and then it's just a noop if GIT_PROVE_OPTS doesn't use --state. But I > haven't played with it myself.
I do not think it warrants such complexity. The wrapper script is fine.