[PATCH] support: Add TEST_COMPARE_BLOB, support_quote_blob

Florian Weimer fweimer@redhat.com
Wed May 16 09:42:00 GMT 2018


On 03/02/2018 05:32 PM, Carlos O'Donell wrote:
> On 03/02/2018 02:59 AM, Florian Weimer wrote:
>> The declaration of support_test_compare_blob uses unsigned long,
>> to avoid including <stddef.h>.
>>
>> 2018-03-02  Florian Weimer  <fweimer@redhat.com>
>>
>> 	* support/Makefile (libsupport-routines): Add support_quote_blob,
>> 	support_test_compare_blob.
>> 	(tests): Add tst-support_quote_blob, tst-test_compare_blob.
>> 	* support/check.h (TEST_COMPARE_BLOB): Define.
>> 	(support_test_compare_blob): Declare.
>> 	* support/support.h (support_quote_blob): Declare.
>> 	* support/support_quote_blob.c: New file.
>> 	* support/support_test_compare_blob.c: Likewise.
>> 	* support/tst-support_quote_blob.c: Likewise.
>> 	* support/tst-test_compare_blob.c: Likewise.
> 
> Please add comments to the test cases to explain why you
> used the particular test data that you did.
> 
> Were you looking to test specific quoting sequences?
> 
> Were you using arbitrary data hand picked by you to test the code?
> 
> Or did you pick the data to trigger branches in the code that were
> part of the implementation?

I added some comments in that direction.  I hope they clarify what is 
being tested.

Thanks,
Florian
-------------- next part --------------
A non-text attachment was scrubbed...
Name: test_compare_blob.patch
Type: text/x-patch
Size: 15959 bytes
Desc: not available
URL: <http://sourceware.org/pipermail/libc-alpha/attachments/20180516/6e8ac664/attachment.bin>


More information about the Libc-alpha mailing list