From: Uwe Hermann Date: Tue, 8 Jan 2019 22:16:37 +0000 (+0100) Subject: tests/init: Multiple Srf::init() calls should throw. X-Git-Url: https://sigrok.org/gitaction?a=commitdiff_plain;h=7dc59fc4a38b6032158d2551cd3c449fe5e87e62;p=libsigrokflow.git tests/init: Multiple Srf::init() calls should throw. --- diff --git a/tests/init.cpp b/tests/init.cpp index 18b7438..89cb23e 100644 --- a/tests/init.cpp +++ b/tests/init.cpp @@ -26,6 +26,10 @@ TEST_CASE("init/deinit", "[init]") SECTION("Srf::init() after successful Gst::init() should not throw") { CHECK_NOTHROW(Srf::init()); + SECTION("Multiple Srf::init() calls should throw") { + for (int i = 0; i < 10; ++i) + CHECK_THROWS(Srf::init()); + } } REQUIRE_NOTHROW(Gst::deinit());