Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(159)

Unified Diff: tests/HashTest.cpp

Issue 948473002: Port GrGLCaps over to use SkTHash. (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: winders Created 5 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « src/gpu/gl/GrGLCaps.cpp ('k') | tests/THashCache.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tests/HashTest.cpp
diff --git a/tests/HashTest.cpp b/tests/HashTest.cpp
index 00857f63dcd61377090f2fc01023e22b84d4376a..623e597eeb2d48dc0238f4a72ae27a8043195558 100644
--- a/tests/HashTest.cpp
+++ b/tests/HashTest.cpp
@@ -39,6 +39,9 @@ DEF_TEST(HashMap, r) {
}
REPORTER_ASSERT(r, map.count() == N);
+
+ map.reset();
+ REPORTER_ASSERT(r, map.count() == 0);
}
namespace { uint32_t hash_string(const SkString& s) { return SkToInt(s.size()); } }
@@ -54,6 +57,9 @@ DEF_TEST(HashSet, r) {
REPORTER_ASSERT(r, set.contains(SkString("Hello")));
REPORTER_ASSERT(r, set.contains(SkString("World")));
REPORTER_ASSERT(r, !set.contains(SkString("Goodbye")));
+
+ set.reset();
+ REPORTER_ASSERT(r, set.count() == 0);
}
namespace {
« no previous file with comments | « src/gpu/gl/GrGLCaps.cpp ('k') | tests/THashCache.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698