From 34a83475636164cf43551d9ec83ec30da5a7e7f2 Mon Sep 17 00:00:00 2001 From: Andrei Karas Date: Thu, 8 Jun 2017 01:22:43 +0300 Subject: Replace size() to empty() where is possible --- src/resources/resourcemanager/resourcemanager_unittest.cc | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) (limited to 'src/resources/resourcemanager') diff --git a/src/resources/resourcemanager/resourcemanager_unittest.cc b/src/resources/resourcemanager/resourcemanager_unittest.cc index 231d5cfc0..fe3e2e995 100644 --- a/src/resources/resourcemanager/resourcemanager_unittest.cc +++ b/src/resources/resourcemanager/resourcemanager_unittest.cc @@ -274,7 +274,7 @@ TEST_CASE("resourcemanager", "resourcemanager") REQUIRE(res2 != nullptr); REQUIRE(testResouceCounter == 1); REQUIRE(res2->mRefCount == 1); - REQUIRE(res2->mSource == ""); + REQUIRE(res2->mSource.empty()); REQUIRE(ResourceManager::getResources().size() == 1 + resSize); REQUIRE(ResourceManager::getResources()["test1"] == res2); REQUIRE(ResourceManager::getOrphanedResources().empty() == true); @@ -302,7 +302,7 @@ TEST_CASE("resourcemanager", "resourcemanager") REQUIRE(res2 != nullptr); REQUIRE(testResouceCounter == 2); REQUIRE(res2->mRefCount == 1); - REQUIRE(res2->mSource == ""); + REQUIRE(res2->mSource.empty()); REQUIRE(ResourceManager::getResources().size() == 2 + resSize); REQUIRE(ResourceManager::getResources()["test1"] == res); REQUIRE(ResourceManager::getResources()["test2"] == res2); @@ -331,7 +331,7 @@ TEST_CASE("resourcemanager", "resourcemanager") REQUIRE(testResouceCounter == 1); REQUIRE(res2->mRefCount == 2); REQUIRE(res == res2); - REQUIRE(res2->mSource == ""); + REQUIRE(res2->mSource.empty()); REQUIRE(ResourceManager::getResources().size() == 1 + resSize); REQUIRE(ResourceManager::getResources()["test1"] == res2); REQUIRE(ResourceManager::getOrphanedResources().empty() == true); @@ -360,7 +360,7 @@ TEST_CASE("resourcemanager", "resourcemanager") REQUIRE(testResouceCounter == 1); REQUIRE(res2->mRefCount == 1); REQUIRE(res == res2); - REQUIRE(res2->mSource == ""); + REQUIRE(res2->mSource.empty()); REQUIRE(ResourceManager::getResources().size() == 1 + resSize); REQUIRE(ResourceManager::getResources()["test1"] == res2); REQUIRE(ResourceManager::getOrphanedResources().empty() == true); @@ -388,7 +388,7 @@ TEST_CASE("resourcemanager", "resourcemanager") REQUIRE(res2 != nullptr); REQUIRE(testResouceCounter == 2); REQUIRE(res2->mRefCount == 1); - REQUIRE(res2->mSource == ""); + REQUIRE(res2->mSource.empty()); REQUIRE(ResourceManager::getResources().size() == 2 + resSize); REQUIRE(ResourceManager::getResources()["test1"] == res); REQUIRE(ResourceManager::getResources()["test2"] == res2); @@ -473,7 +473,7 @@ TEST_CASE("resourcemanager", "resourcemanager") REQUIRE(testResouceCounter == 1); REQUIRE(res2->mRefCount == 1); REQUIRE(res == res2); - REQUIRE(res2->mSource == ""); + REQUIRE(res2->mSource.empty()); REQUIRE(ResourceManager::getResources().size() == 1 + resSize); REQUIRE(ResourceManager::getResources()["test1"] == res2); REQUIRE(ResourceManager::getOrphanedResources().empty() == true); -- cgit v1.2.3-70-g09d2