Consensus on unit tests?

Florian Weimer fweimer@redhat.com
Fri Jul 1 06:43:00 GMT 2016


On 06/25/2016 01:59 AM, Carlos O'Donell wrote:

> I would like to remove the superfluous condition and add a
> unit test for all the cases that define the way the interface
> should behave.
>
> Since Florian asked for pretty diagrams, I have included them.

I can't quote your patch due to the way it is included in the message 
(inline text after the signature).

What's unclear based on the documentation if the address has to fall in 
the range covered by the link map (i.e., if there are indeed only three 
cases, or five).  If there is indeed a precondition that the address is 
in some special range, you should add it to the comment.

There is also a stray comment in the function itself.

> Should we allow unit tests for the dynamic loader?

I expect unit tests which look like this to be noncontroversial.

Things are more interesting if you have to add testing hooks to the 
code, or export additional symbols.

Thanks,
Florian



More information about the Libc-alpha mailing list