diff --git a/tests/util.cpp b/tests/util.cpp index dd939e29..f38c37a8 100644 --- a/tests/util.cpp +++ b/tests/util.cpp @@ -86,13 +86,13 @@ TEST_CASE("String", "[.util]") { } SECTION("fromnullable") { - REQUIRE(dxvk::str::fromnullable(nullptr) == std::string()); - REQUIRE(dxvk::str::fromnullable("") == std::string()); + REQUIRE(dxvk::str::fromnullable(nullptr).empty()); + REQUIRE(dxvk::str::fromnullable("").empty()); REQUIRE(dxvk::str::fromnullable("string") == "string"); } SECTION("split") { - REQUIRE(dxvk::str::split>("", std::regex(",")).size() == 0); + REQUIRE(dxvk::str::split>("", std::regex(",")).empty()); auto result = dxvk::str::split>("foo,bar,baz", std::regex(",")); @@ -132,7 +132,7 @@ TEST_CASE("String", "[.util]") { } SECTION("implode") { - REQUIRE(dxvk::str::implode(",", std::vector{}) == std::string()); + REQUIRE(dxvk::str::implode(",", std::vector{}).empty()); REQUIRE(dxvk::str::implode(",", std::vector{"foo"}) == "foo"); REQUIRE(dxvk::str::implode(" ", std::vector{"foo", "bar"}) == "foo bar"); REQUIRE(dxvk::str::implode(", ", std::vector{"foo", "bar", "baz"}) == "foo, bar, baz");