[PATCH v2 0/4] Support for running tests outside t/ + don't run a TODO test
- From
Ævar Arnfjörð Bjarmason <avarab@gmail.com>
- Date
- Aug 18, 2010, 13:34 UTC
- Message-ID
- <1282138473-15613-1-git-send-email-avarab@gmail.com>
- In-Reply-To
- <7vpqxhaw92.fsf@alter.siamese.dyndns.org>
On Tue, Aug 17, 2010 at 19:12, Junio C Hamano <gitster@pobox.com> wrote:
Show 14 quoted lines
> Sverre Rabbelier <srabbelier@gmail.com> writes: > >> E.g., something like: >> >> test_in_new_harness 0 1 0 0 ' >> test_expect_failure 'pretend we have fixed a known breakage' ' >> : >> ' >> ' > > Now the question becomes who tests "test_in_new_harness" ;-) > > I'd rather prefer not to touch this one. Isn't whatever the outer wrapper > used flexible enough to be taught about this kind of thing and filter it?
The problem is that you have to modify *all* the outer wrappers. Since the test suite can be run with any TAP consumer that isn't viable, and at the very least having to do:
prove --source=Some::Custom::Git Thing ...
Is tedious, and requires us to maintain the Some::Custom::Git thingy.
Anyway, here's a better patch. It allows us to run a pasing TODO test, check if it works, and if so not mark *that* test as passing TODO, but simply as passing.
As a side benefit it makes the test lib more awesome.
Ævar Arnfjörð Bjarmason (4):
test-lib: Use $TEST_DIRECTORY or $GIT_BUILD_DIR instead of $(pwd) and
../
test-lib: Use "$GIT_BUILD_DIR" instead of "$TEST_DIRECTORY"/../
test-lib: Allow overriding of TEST_DIRECTORY
t/t0000-basic.sh: Run the passing TODO test inside its own test-libt/t0000-basic.sh | 31 +++++++++++++++++++++++++++++++ t/test-lib.sh | 39 +++++++++++++++++++++++---------------- 2 files changed, 54 insertions(+), 16 deletions(-)
-- 1.7.2.1.414.g9bf49