Re: [PATCH v2] t1402: test forbidden characters in refnames

Nikolaus Schuetz <[email protected]>
Newsgroups org.kernel.vger.git
Message-ID <[email protected]>
> Many funny characters are not allowed between 'foo' and 'bar', but
> are there characters other than dot that are not allowed at the
> beginning or at the end (e.g., "refs/heads/foo." and "foo.lock")?
>
> IOW are we testing exhaustive now?

No -- dot is the only character with position-specific rules,
and every other character in the forbidden set is rejected
anywhere in a component.

The file already exercises each of those rules on its own -- the
leading/trailing-dot, ".lock", empty-component, single-level and
--normalize cases are all present. So this isn't reaching for
exhaustiveness; the coverage was already broad, and this just
fills the untested gap -- of the "forbidden anywhere" characters,
only "?", "\" and ".." were tested embedded, so I folded the rest
into the loop.

Thanks,
Nikolaus
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.