threads / discuss / 5478

Test names

Subject: Test names

## tl;dr

2 messages between Sep 5, 2006 and Sep 5, 2006.

replies: 1people: 2as markdown or json

Jakub Narebski· Sep 5, 2006, 00:10 UTC · lore
In t/README it is written:
Show 11 quoted lines
> The test files are named as:
>
>         tNNNN-commandname-details.sh
>
> where N is a decimal digit.
>
> First digit tells the family:
>
>         0 - the absolute basics and global stuff
> [...]
>         7 - the porcelainish commands concerning the working tree

There are now some test which have 8 or 9 as first digit (e.g. t8002-blame.sh, t9001-send-email.sh). What is the family for them? What number for example gitweb test should have?

> Second digit tells the particular command we are testing.

Is there any naming rule, or just increment it by one when adding new test in the same family?

> Third digit (optionally) tells the particular switch or group of switches
>  we are testing.
What tells the fourth digit?
-- 
Jakub Narebski
Warsaw, Poland
ShadeHawk on #git
Junio C Hamano· Sep 5, 2006, 08:28 UTC · re: Jakub Narebski · lore

Re: Test names

Jakub Narebski <jnareb@gmail.com> writes:
Show 9 quoted lines
> In t/README it is written:
>...
> Is there any naming rule, or just increment it by one when adding new test
> in the same family?
>
>> Third digit (optionally) tells the particular switch or group of switches
>>  we are testing.
>
> What tells the fourth digit?

Nothing other than just to make them aline up and ordered nicely.

The rule was outlined long time ago but not strictly followed (primarily because was done when git was mostly core, and it did not anticipate the proliferation of Porcelain-ish wrappers, so it was rather hard to follow). I'd suggest you to declare that t92xx- series are for gitweb, and organize the tests in that namespace nicely. Also you might want to see what Eric did for the subversion interface tests (60d02cc declares that t91xx- series are SVN tests and gives an easy way to skip heavier tests on git-svn).

← back to recent threads