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

Unified Diff: src/gpu/gr_unittests.cpp

Issue 22850006: Replace uses of GrAssert by SkASSERT. (Closed) Base URL: https://skia.googlecode.com/svn/trunk
Patch Set: rebase Created 7 years, 4 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/debug/GrDebugGL.cpp ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/gpu/gr_unittests.cpp
diff --git a/src/gpu/gr_unittests.cpp b/src/gpu/gr_unittests.cpp
index 618d412bb5a8ff09606ff024cb13ebe5e96a42a0..a6a43c4f27b4491a8e8a64d19d66f37bf41c9b04 100644
--- a/src/gpu/gr_unittests.cpp
+++ b/src/gpu/gr_unittests.cpp
@@ -34,9 +34,9 @@ static void test_bsearch() {
for (size_t n = 0; n < GR_ARRAY_COUNT(array); n++) {
for (size_t i = 0; i < n; i++) {
int index = GrTBSearch<int, int>(array, n, array[i]);
- GrAssert(index == (int) i);
+ SkASSERT(index == (int) i);
index = GrTBSearch<int, int>(array, n, -array[i]);
- GrAssert(index < 0);
+ SkASSERT(index < 0);
}
}
}
@@ -59,17 +59,17 @@ static void test_binHashKey()
keyA.setKeyData(testStringA);
// test copy constructor and comparison
GrTBinHashKey<BogusEntry, kDataLenUsedForKey> keyA2(keyA);
- GrAssert(keyA.compare(keyA2) == 0);
- GrAssert(keyA.getHash() == keyA2.getHash());
+ SkASSERT(keyA.compare(keyA2) == 0);
+ SkASSERT(keyA.getHash() == keyA2.getHash());
// test re-init
keyA2.setKeyData(testStringA);
- GrAssert(keyA.compare(keyA2) == 0);
- GrAssert(keyA.getHash() == keyA2.getHash());
+ SkASSERT(keyA.compare(keyA2) == 0);
+ SkASSERT(keyA.getHash() == keyA2.getHash());
// test sorting
GrTBinHashKey<BogusEntry, kDataLenUsedForKey> keyB;
keyB.setKeyData(testStringB);
- GrAssert(keyA.compare(keyB) < 0);
- GrAssert(keyA.getHash() != keyB.getHash());
+ SkASSERT(keyA.compare(keyB) < 0);
+ SkASSERT(keyA.getHash() != keyB.getHash());
}
« no previous file with comments | « src/gpu/gl/debug/GrDebugGL.cpp ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698