[PATCH wayland] tests: Add nullable check to wl_message_count_arrays

Pekka Paalanen ppaalanen at gmail.com
Fri Nov 18 15:04:50 UTC 2016


On Fri, 11 Nov 2016 07:08:09 -0800
Yong Bakos <junk at humanoriented.com> wrote:

> From: Yong Bakos <ybakos at humanoriented.com>
> 
> Array argument symbols in a wl_message may be nullable, but the test for
> wl_message_count_arrays did not test this. Add one more wl_message with
> nullable array arguments.
> 
> Signed-off-by: Yong Bakos <ybakos at humanoriented.com>
> ---
>  tests/message-test.c | 6 ++++--
>  1 file changed, 4 insertions(+), 2 deletions(-)
> 
> diff --git a/tests/message-test.c b/tests/message-test.c
> index 389f788..4e69392 100644
> --- a/tests/message-test.c
> +++ b/tests/message-test.c
> @@ -64,7 +64,8 @@ TEST(message_count_arrays)
>  		{ "multiple", "aaiufaasonhaa", NULL },
>  		{ "leading_version", "2aaiufaasonhaa", NULL },
>  		{ "among_nullables", "iufsa?oa?nah", NULL },
> -		{ "all_mixed", "2aiufas?oa?na", NULL },
> +		{ "nullable", "?aiufs?a?onh?a", NULL },
> +		{ "all_mixed", "2?aiufas?oa?na", NULL },
>  	};
>  	const struct {
>  		const struct wl_message *message;
> @@ -80,7 +81,8 @@ TEST(message_count_arrays)
>  		{ &fake_messages[5], 6 },
>  		{ &fake_messages[6], 6 },
>  		{ &fake_messages[7], 3 },
> -		{ &fake_messages[8], 4 }
> +		{ &fake_messages[8], 3 },
> +		{ &fake_messages[9], 4 },
>  	};
>  
>  	for (i = 0; i < ARRAY_LENGTH(messages); ++i) {

Pushed:
   b0cd65d..2d328a4  master -> master


Thanks,
pq
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 801 bytes
Desc: OpenPGP digital signature
URL: <https://lists.freedesktop.org/archives/wayland-devel/attachments/20161118/d44b2c52/attachment.sig>


More information about the wayland-devel mailing list