Home | History | Annotate | Download | only in tests

Lines Matching refs:Reporter

55 static void compare_bitmaps(skiatest::Reporter* reporter,
58 REPORTER_ASSERT(reporter, b1.empty() == b2.empty());
59 REPORTER_ASSERT(reporter, b1.width() == b2.width());
60 REPORTER_ASSERT(reporter, b1.height() == b2.height());
61 REPORTER_ASSERT(reporter, b1.isNull() == b2.isNull());
64 REPORTER_ASSERT(reporter, b1.isNull() == b2.isNull());
68 REPORTER_ASSERT(reporter, NULL != b1.getPixels());
69 REPORTER_ASSERT(reporter, NULL != b2.getPixels());
89 REPORTER_ASSERT(reporter, 0 == pixelErrors);
97 static void test_three_encodings(skiatest::Reporter* reporter,
101 REPORTER_ASSERT(reporter, !original.empty());
102 REPORTER_ASSERT(reporter, !original.isNull());
114 REPORTER_ASSERT(reporter, encoded.get() != NULL);
120 REPORTER_ASSERT(reporter, installSuccess);
124 REPORTER_ASSERT(reporter, NULL == lazy.getPixels());
127 REPORTER_ASSERT(reporter, NULL != lazy.getPixels());
133 REPORTER_ASSERT(reporter, NULL == lazy.getPixels());
136 REPORTER_ASSERT(reporter, NULL != lazy.getPixels());
142 compare_bitmaps(reporter, original, lazy, comparePixels);
162 DEF_TEST(DecodingImageGenerator, reporter) {
163 test_three_encodings(reporter, install_skCachingPixelRef);
164 test_three_encodings(reporter, install_skDiscardablePixelRef);
180 TestImageGenerator(TestType type, skiatest::Reporter* reporter)
181 : fType(type), fReporter(reporter) {
218 skiatest::Reporter* const fReporter;
220 void CheckTestImageGeneratorBitmap(skiatest::Reporter* reporter,
222 REPORTER_ASSERT(reporter, TestImageGenerator::Width() == bm.width());
223 REPORTER_ASSERT(reporter, TestImageGenerator::Height() == bm.height());
225 REPORTER_ASSERT(reporter, NULL != bm.getPixels());
237 REPORTER_ASSERT(reporter, 0 == errors);
246 skiatest::Reporter* reporter,
251 (type, reporter)));
252 REPORTER_ASSERT(reporter, gen.get() != NULL);
261 REPORTER_ASSERT(reporter, success
264 CheckTestImageGeneratorBitmap(reporter, lazy);
267 REPORTER_ASSERT(reporter, NULL == lazy.getPixels());
273 static void test_newlockdelete(skiatest::Reporter* reporter) {
277 reporter);
287 DEF_TEST(DiscardableAndCachingPixelRef, reporter) {
288 test_newlockdelete(reporter);
291 reporter, kSkCaching_PixelRefType, NULL);
293 reporter, kSkCaching_PixelRefType, NULL);
295 reporter, kSkCaching_PixelRefType, NULL);
298 reporter, kSkDiscardable_PixelRefType, NULL);
300 reporter, kSkDiscardable_PixelRefType, NULL);
302 reporter, kSkDiscardable_PixelRefType, NULL);
306 REPORTER_ASSERT(reporter, 0 == pool->getRAMUsed());
308 reporter, kSkDiscardable_PixelRefType, pool);
309 REPORTER_ASSERT(reporter, 0 == pool->getRAMUsed());
311 reporter, kSkDiscardable_PixelRefType, pool);
312 REPORTER_ASSERT(reporter, 0 == pool->getRAMUsed());
319 reporter, kSkDiscardable_PixelRefType, globalPool);
321 reporter, kSkDiscardable_PixelRefType, globalPool);