diff options
| author | Yong Bakos <ybakos@humanoriented.com> | 2016-11-11 07:08:09 -0800 |
|---|---|---|
| committer | Pekka Paalanen <pekka.paalanen@collabora.co.uk> | 2016-11-18 16:59:23 +0200 |
| commit | 2d328a4559152ed11e52bdbd85689d7b2239596a (patch) | |
| tree | 1d3d535fe88f2dc578374055d328f39c37f09be7 /tests/message-test.c | |
| parent | tests: Test wl_interface_equal (diff) | |
| download | wayland-2d328a4559152ed11e52bdbd85689d7b2239596a.tar wayland-2d328a4559152ed11e52bdbd85689d7b2239596a.tar.gz wayland-2d328a4559152ed11e52bdbd85689d7b2239596a.tar.bz2 wayland-2d328a4559152ed11e52bdbd85689d7b2239596a.tar.lz wayland-2d328a4559152ed11e52bdbd85689d7b2239596a.tar.xz wayland-2d328a4559152ed11e52bdbd85689d7b2239596a.tar.zst wayland-2d328a4559152ed11e52bdbd85689d7b2239596a.zip | |
tests: Add nullable check to wl_message_count_arrays
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@humanoriented.com>
Reviewed-by: Pekka Paalanen <pekka.paalanen@collabora.co.uk>
Diffstat (limited to 'tests/message-test.c')
| -rw-r--r-- | tests/message-test.c | 6 |
1 files 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) { |
