From: Kent Gibson Date: Wed, 14 Oct 2020 03:47:58 +0000 (+0800) Subject: tests: add check of event offset to wait_multiple X-Git-Url: http://git.maquefel.me/?a=commitdiff_plain;h=bf9d51440855c76e15939c95cdd8adba0c8705d8;p=qemu-gpiodev%2Flibgpiod.git tests: add check of event offset to wait_multiple The offset field is added for uAPI v2, so extend the test to check that the value returned is correct. Signed-off-by: Kent Gibson Signed-off-by: Bartosz Golaszewski --- diff --git a/tests/tests-event.c b/tests/tests-event.c index 6066e45..9b66f05 100644 --- a/tests/tests-event.c +++ b/tests/tests-event.c @@ -570,6 +570,7 @@ GPIOD_TEST_CASE(wait_multiple, 0, { 8 }) ret = gpiod_line_event_read(line, &ev); g_assert_cmpint(ret, ==, 0); g_assert_cmpint(ev.event_type, ==, GPIOD_LINE_EVENT_RISING_EDGE); + g_assert_cmpint(ev.offset, ==, 4); } GPIOD_TEST_CASE(get_fd_when_values_requested, 0, { 8 })