Re: [PATCHv6 01/16] test-lib: make test_expect_code a test command
- From
Junio C Hamano <gitster@pobox.com>
- Date
- Oct 4, 2010, 00:54 UTC
- Message-ID
- <7vfwwmdbgl.fsf@alter.siamese.dyndns.org>
- In-Reply-To
- <1286136014-7728-2-git-send-email-newren@gmail.com>
Elijah Newren <newren@gmail.com> writes:
Show 12 quoted lines
> diff --git a/t/t0000-basic.sh b/t/t0000-basic.sh > index f688bd3..c2f5f8d 100755 > --- a/t/t0000-basic.sh > +++ b/t/t0000-basic.sh > @@ -130,22 +130,57 @@ test_expect_success 'tests clean up after themselves' ' > ... > +#!$SHELL_PATH > + > +test_description='Failing tests with cleanup commands' > + > +# Point to the t/test-lib.sh, which isn't in ../ as usual > +TEST_DIRECTORY=\"$TEST_DIRECTORY\"
Do we know at this point that the string in $TEST_DIRECTORY can safely be quoted by just a simple dq pair? I don't think so--isn't the leading part of that string whatever the user can choose (i.e. $(cwd))?
This seems sloppy.
> +. \"\$TEST_DIRECTORY\"/test-lib.sh
Once you get the right value in TEST_DIRECTORY, this one is correct.