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

Unified Diff: tests/BitmapHasherTest.cpp

Issue 510423005: make allocPixels throw on failure (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: rebase Created 6 years, 3 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 | « tests/BitmapCopyTest.cpp ('k') | tests/BitmapTest.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tests/BitmapHasherTest.cpp
diff --git a/tests/BitmapHasherTest.cpp b/tests/BitmapHasherTest.cpp
index e39439a11f468170cf711d4c32f8d1a1a0f3e945..3b5170692d1aad8eedb955bbdfa9ce61e8ac51c6 100644
--- a/tests/BitmapHasherTest.cpp
+++ b/tests/BitmapHasherTest.cpp
@@ -17,8 +17,7 @@ typedef uint64_t checksum_result;
// Fill in bitmap with test data.
static void CreateTestBitmap(SkBitmap* bitmap, int width, int height,
SkColor color, skiatest::Reporter* reporter) {
- SkImageInfo info = SkImageInfo::MakeN32(width, height, kOpaque_SkAlphaType);
- REPORTER_ASSERT(reporter, bitmap->allocPixels(info));
+ bitmap->allocN32Pixels(width, height, kOpaque_SkAlphaType);
bitmap->eraseColor(color);
}
« no previous file with comments | « tests/BitmapCopyTest.cpp ('k') | tests/BitmapTest.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698