bindings: cxx: tests: fix the test case for chip::unwatch_line_info()
authorBartosz Golaszewski <bartosz.golaszewski@linaro.org>
Thu, 16 Mar 2023 10:59:13 +0000 (11:59 +0100)
committerBartosz Golaszewski <bartosz.golaszewski@linaro.org>
Thu, 16 Mar 2023 10:59:13 +0000 (11:59 +0100)
We need to actually trigger a line-info event before making sure the watch
has been disabled.

Fixes: f2245fa32c1b ("bindings: cxx: tests: add a test case for chip::unwatch_line_info()")
Signed-off-by: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>
bindings/cxx/tests/tests-info-event.cpp

index ee3149675b05252e8f93ef580e3ad334e51ea4e0..249b1e8161c43d2385f5107b4dc516907944a725 100644 (file)
@@ -124,6 +124,8 @@ TEST_CASE("line info can be unwatched", "[info-event]")
 
        chip.unwatch_line_info(5);
 
+       request.release();
+
        REQUIRE_FALSE(chip.wait_info_event(::std::chrono::milliseconds(100)));
 }