Re: [PATCH 2/2] test-lib: GIT_TEST_ONLY to run only specific tests
- From
- Ilya Bobyr <ilya.bobir@gmail.com>
- Date
- Mar 3, 2014, 23:16 UTC
- Message-ID
- <53150D68.7070803@gmail.com>
- In-Reply-To
- <CAPig+cT46ekT87TuoTtwvt0G+DraB9cdgW1wd6NsodjJ5FmJrA@mail.gmail.com>
On 3/3/2014 3:03 PM, Eric Sunshine wrote:
> On Mon, Mar 3, 2014 at 5:24 AM, Ilya Bobyr <ilya.bobyr@gmail.com> wrote: >> This is a counterpart to GIT_SKIP_TESTS. Mostly useful when debugging. > To be grammatically similar to GIT_SKIP_TESTS, perhaps name it GIT_RUN_TESTS?
There is actually an upside in the fact that the name is "different enough". When you pull a command from a history it is easier to see if it is the excluding or the including one. Maybe we can have a third opinion here?
Show 26 quoted lines
>> ---
>> t/README | 15 +++++++++++++++
>> t/test-lib.sh | 8 ++++++++
>> 2 files changed, 23 insertions(+), 0 deletions(-)
>>
>> diff --git a/t/README b/t/README
>> index caeeb9d..f939987 100644
>> --- a/t/README
>> +++ b/t/README
>> @@ -187,6 +187,21 @@ and either can match the "t[0-9]{4}" part to skip the whole
>> test, or t[0-9]{4} followed by ".$number" to say which
>> particular test to skip.
>>
>> +Sometimes the opposite is desired - ability to execute only one or
>> +several tests. Mostly while debugging tests. For that you can say
>> +
>> + $ GIT_TEST_ONLY=t9200.8 sh ./t9200-git-cvsexport-commit.sh
>> +
>> +or, similrary to GIT_SKIP_TESTS
>> +
>> + $ GIT_TEST_ONLY='t[0-4]??? t91?? t9200.8' make
>> +
>> +In additiona to matching against "<test suite number>.<test number>"
> s/additiona/addition/
>
> Plus the other typos already mentioned by Philip...Thank you. I will include all of those in the next version of the patch.
> [...]