diff --git a/tests/extensions.cpp b/tests/extensions.cpp index ee5ae30..6712b3e 100644 --- a/tests/extensions.cpp +++ b/tests/extensions.cpp @@ -122,7 +122,7 @@ TEST_CASE("Monadic operations", "[monadic]") { // callable which returns a reference tl::optional o38 = 42; - auto o38r = o38.map([](int& i) -> const int& { return i; }); + auto o38r = o38.map([](int &i) -> const int & { return i; }); REQUIRE(o38r); REQUIRE(*o38r == 42); } diff --git a/tests/make_optional.cpp b/tests/make_optional.cpp index 0376849..ba44fd9 100644 --- a/tests/make_optional.cpp +++ b/tests/make_optional.cpp @@ -41,4 +41,6 @@ TEST_CASE("Make optional", "[make_optional]") { auto i = 42; auto o6 = tl::make_optional(i); REQUIRE((std::is_same>::value)); + REQUIRE(o6); + REQUIRE(*o6 == 42); }