/external/skia/tests/ |
LayerDrawLooperTest.cpp | 56 REPORTER_ASSERT(reporter, looper->next(&canvas, &paint)); 57 REPORTER_ASSERT(reporter, SkXfermode::IsMode(paint.getXfermode(), SkXfermode::kSrc_Mode)); 59 REPORTER_ASSERT(reporter, SkFloatToScalar(10.0f) == device.fLastMatrix.getTranslateX()); 60 REPORTER_ASSERT(reporter, SkFloatToScalar(20.0f) == device.fLastMatrix.getTranslateY()); 64 REPORTER_ASSERT(reporter, looper->next(&canvas, &paint)); 65 REPORTER_ASSERT(reporter, SkXfermode::IsMode(paint.getXfermode(), SkXfermode::kSrcOver_Mode)); 67 REPORTER_ASSERT(reporter, SkFloatToScalar(0.0f) == device.fLastMatrix.getTranslateX()); 68 REPORTER_ASSERT(reporter, SkFloatToScalar(0.0f) == device.fLastMatrix.getTranslateY()); 71 REPORTER_ASSERT(reporter, !looper->next(&canvas, &paint)); 93 REPORTER_ASSERT(reporter, looper->next(&canvas, &paint)) [all...] |
ClipStackTest.cpp | 23 REPORTER_ASSERT(reporter, 0 == s.getSaveCount()); 27 REPORTER_ASSERT(reporter, 1 == s.getSaveCount()); 37 REPORTER_ASSERT(reporter, 2 == s.getSaveCount()); 45 REPORTER_ASSERT(reporter, 3 == s.getSaveCount()); 52 REPORTER_ASSERT(reporter, s == copy); 56 REPORTER_ASSERT(reporter, 2 == s.getSaveCount()); 57 REPORTER_ASSERT(reporter, s != copy); 61 REPORTER_ASSERT(reporter, 3 == s.getSaveCount()); 65 REPORTER_ASSERT(reporter, s == copy); 69 REPORTER_ASSERT(reporter, 2 == s.getSaveCount()) [all...] |
MemsetTest.cpp | 16 REPORTER_ASSERT(reporter, 0 == alloc.totalCapacity()); 17 REPORTER_ASSERT(reporter, 0 == alloc.totalUsed()); 18 REPORTER_ASSERT(reporter, 0 == alloc.blockCount()); 19 REPORTER_ASSERT(reporter, !alloc.contains(NULL)); 20 REPORTER_ASSERT(reporter, !alloc.contains(reporter)); 23 REPORTER_ASSERT(reporter, 0 == alloc.totalCapacity()); 24 REPORTER_ASSERT(reporter, 0 == alloc.totalUsed()); 25 REPORTER_ASSERT(reporter, 0 == alloc.blockCount()); 29 REPORTER_ASSERT(reporter, alloc.totalCapacity() >= size); 30 REPORTER_ASSERT(reporter, alloc.totalUsed() == size) [all...] |
RefCntTest.cpp | 34 REPORTER_ASSERT(reporter, 0 == InstCounterClass::gInstCounter); 39 REPORTER_ASSERT(reporter, 1 == array->getRefCnt()); 40 REPORTER_ASSERT(reporter, N == array->count()); 42 REPORTER_ASSERT(reporter, N == InstCounterClass::gInstCounter); 44 REPORTER_ASSERT(reporter, 0 == InstCounterClass::gInstCounter); 50 REPORTER_ASSERT(reporter, N == InstCounterClass::gInstCounter); 52 REPORTER_ASSERT(reporter, i == src[i].fCount); 56 REPORTER_ASSERT(reporter, 1 == array->getRefCnt()); 57 REPORTER_ASSERT(reporter, N == array->count()); 59 REPORTER_ASSERT(reporter, 2*N == InstCounterClass::gInstCounter) [all...] |
Writer32Test.cpp | 19 REPORTER_ASSERT(reporter, writer.bytesWritten() == size); 21 REPORTER_ASSERT(reporter, !memcmp(storage.get(), expected, size)); 37 REPORTER_ASSERT(reporter, NULL == str); 38 REPORTER_ASSERT(reporter, 0 == len); 48 REPORTER_ASSERT(reporter, 0 == strcmp("", str)); 49 REPORTER_ASSERT(reporter, 0 == len); 56 REPORTER_ASSERT(reporter, 0 == writer.bytesWritten()); 63 REPORTER_ASSERT(reporter, sizeof(array) - 4 == writer.bytesWritten()); 65 REPORTER_ASSERT(reporter, sizeof(array) == writer.bytesWritten()); 76 REPORTER_ASSERT(reporter, 100*4 == writer.bytesWritten()) [all...] |
FlateTest.cpp | 47 REPORTER_ASSERT(reporter, status); 53 REPORTER_ASSERT(reporter, testData.getLength() == inputSize); 54 REPORTER_ASSERT(reporter, memcmp(testData.getMemoryBase(), 60 REPORTER_ASSERT(reporter, compressed.getOffset() < 1024); 62 REPORTER_ASSERT(reporter, compressed.getOffset() > 1024); 69 REPORTER_ASSERT(reporter, status); 75 REPORTER_ASSERT(reporter, data1->size() == inputSize); 76 REPORTER_ASSERT(reporter, memcmp(testStream->getMemoryBase(), 82 REPORTER_ASSERT(reporter, testData.getLength() == uncompressed.getOffset()); 83 REPORTER_ASSERT(reporter, memcmp(testData.getMemoryBase() [all...] |
HashCacheTest.cpp | 100 REPORTER_ASSERT(reporter, 10 == cache.count()); 105 REPORTER_ASSERT(reporter, NULL != found && -i == found->fValue); 111 REPORTER_ASSERT(reporter, NULL == found); 119 REPORTER_ASSERT(reporter, 20 == cache.count()); 126 REPORTER_ASSERT(reporter, NULL == found); 131 REPORTER_ASSERT(reporter, NULL != found && found->fValue > 0); 140 REPORTER_ASSERT(reporter, NULL == found); 145 REPORTER_ASSERT(reporter, NULL != found && found->fValue < 0); 153 REPORTER_ASSERT(reporter, 18 == cache.count()); 156 REPORTER_ASSERT(reporter, NULL == found) [all...] |
ColorFilterTest.cpp | 56 REPORTER_ASSERT(reporter, cf); 66 REPORTER_ASSERT(reporter, cf->asColorMode(&c, &m)); 79 REPORTER_ASSERT(reporter, c == expectedColor); 80 REPORTER_ASSERT(reporter, m == expectedMode); 85 REPORTER_ASSERT(reporter, cf2); 89 REPORTER_ASSERT(reporter, cf2->asColorMode(&c2, &m2)); 90 REPORTER_ASSERT(reporter, c2 == expectedColor); 91 REPORTER_ASSERT(reporter, m2 == expectedMode);
|
OSPathTest.cpp | 38 REPORTER_ASSERT(reporter, fullName.size() == expectedSize); 43 REPORTER_ASSERT(reporter, basename.equals(filename)); 46 REPORTER_ASSERT(reporter, !basename.contains(SkPATH_SEPARATOR)); 50 REPORTER_ASSERT(reporter, basename.equals(filename)); 75 REPORTER_ASSERT(reporter, baseOfDir.size() == 0); 79 REPORTER_ASSERT(reporter, empty.size() == 0); 83 REPORTER_ASSERT(reporter, emptyPath.size() == 1); 84 REPORTER_ASSERT(reporter, emptyPath.contains(SkPATH_SEPARATOR));
|
PathOpsDLineTest.cpp | 38 REPORTER_ASSERT(reporter, line[0] == line2[0] && line[1] == line2[1]); 44 REPORTER_ASSERT(reporter, 0); 47 REPORTER_ASSERT(reporter, line[0] == line2[1] && line[1] == line2[0]); 49 REPORTER_ASSERT(reporter, line[0] == line2[1] && line[1] == line2[0]); 51 REPORTER_ASSERT(reporter, approximately_equal((line[0].fX + line[1].fX) / 2, mid.fX)); 52 REPORTER_ASSERT(reporter, approximately_equal((line[0].fY + line[1].fY) / 2, mid.fY));
|
PictureUtilsTest.cpp | 16 REPORTER_ASSERT(reporter, result.equals("test/path/test")); 23 REPORTER_ASSERT(reporter, result.equals("basename")); 28 REPORTER_ASSERT(reporter, result.equals("dir")); 33 REPORTER_ASSERT(reporter, result.equals("path")); 39 REPORTER_ASSERT(reporter, result.equals("winbasename")); 44 REPORTER_ASSERT(reporter, result.equals("windir"));
|
SrcOverTest.cpp | 49 REPORTER_ASSERT(reporter, opaqueCounter0 == 256); 50 REPORTER_ASSERT(reporter, opaqueCounter1 == 256); 51 REPORTER_ASSERT(reporter, opaqueCounter2 == 256); 62 REPORTER_ASSERT(reporter, r0 <= 255 && r0 >= max); 64 REPORTER_ASSERT(reporter, r1 <= 255 && r1 >= max); 65 REPORTER_ASSERT(reporter, r2 <= 255 && r2 >= max);
|
ChecksumTest.cpp | 64 REPORTER_ASSERT(fReporter, 67 REPORTER_ASSERT(fReporter, 84 REPORTER_ASSERT(fReporter, checksum_size <= buf_size); 87 REPORTER_ASSERT(fReporter, prev != curr); 89 REPORTER_ASSERT(fReporter, again == curr); 118 REPORTER_ASSERT(fReporter, ComputeChecksum(NULL, 0) == 0); 128 REPORTER_ASSERT(fReporter, colision1); 129 REPORTER_ASSERT(fReporter, colision2); 131 REPORTER_ASSERT(fReporter, !colision1); 132 REPORTER_ASSERT(fReporter, !colision2) [all...] |
DataRefTest.cpp | 19 REPORTER_ASSERT(reporter, a->count() == b->count()); 24 REPORTER_ASSERT(reporter, sizea == sizeb); 25 REPORTER_ASSERT(reporter, !memcmp(mema, memb, sizea)); 46 REPORTER_ASSERT(reporter, table->isEmpty()); 47 REPORTER_ASSERT(reporter, 0 == table->count()); 74 REPORTER_ASSERT(reporter, itable->count() == icount); 77 REPORTER_ASSERT(reporter, sizeof(int) == itable->atSize(i)); 78 REPORTER_ASSERT(reporter, *itable->atT<int>(i, &size) == idata[i]); 79 REPORTER_ASSERT(reporter, sizeof(int) == size); 97 REPORTER_ASSERT(reporter, table->count() == count) [all...] |
LListTest.cpp | 40 REPORTER_ASSERT(reporter, empty == list.isEmpty()); 43 REPORTER_ASSERT(reporter, numElements == list.countEntries()); 44 REPORTER_ASSERT(reporter, in0 == list.isInList(&elements[0])); 45 REPORTER_ASSERT(reporter, in1 == list.isInList(&elements[1])); 46 REPORTER_ASSERT(reporter, in2 == list.isInList(&elements[2])); 47 REPORTER_ASSERT(reporter, in3 == list.isInList(&elements[3])); 79 REPORTER_ASSERT(reporter, cur->fID == 3-i); 84 REPORTER_ASSERT(reporter, cur->fID == i); 120 REPORTER_ASSERT(reporter, cur->fID == i); 142 REPORTER_ASSERT(reporter, list1.isEmpty()) [all...] |
ImageCacheTest.cpp | 31 REPORTER_ASSERT(reporter, NULL == id); 35 REPORTER_ASSERT(reporter, NULL != id); 40 REPORTER_ASSERT(reporter, id == id2); 41 REPORTER_ASSERT(reporter, tmp.pixelRef() == tmp2.pixelRef()); 42 REPORTER_ASSERT(reporter, tmp.width() == tmp2.width()); 43 REPORTER_ASSERT(reporter, tmp.height() == tmp2.height()); 57 REPORTER_ASSERT(reporter, NULL != id);
|
BitmapFactoryTest.cpp | 49 REPORTER_ASSERT(reporter, bm1.width() == bm2.width()); 50 REPORTER_ASSERT(reporter, bm1.height() == bm2.height()); 63 REPORTER_ASSERT(reporter, cache->getMemoryStatus(ID) == SkImageCache::kPinned_MemoryStatus); 65 REPORTER_ASSERT(reporter, cache->getMemoryStatus(ID) != SkImageCache::kPinned_MemoryStatus); 69 REPORTER_ASSERT(reporter, cache->getMemoryStatus(ID) 72 REPORTER_ASSERT(reporter, !memcmp(memory, (void*) buffer, size)); 75 REPORTER_ASSERT(reporter, cache->getMemoryStatus(ID) 78 REPORTER_ASSERT(reporter, cache->getMemoryStatus(ID) 85 REPORTER_ASSERT(reporter, cache->getMemoryStatus(ID) 88 REPORTER_ASSERT(reporter, cache->getMemoryStatus(ID [all...] |
ClipCacheTest.cpp | 85 REPORTER_ASSERT(reporter, screen == devStackBounds); 86 REPORTER_ASSERT(reporter, isIntersectionOfRects); 98 REPORTER_ASSERT(reporter, intScreen == devGrClipDataBound); 99 REPORTER_ASSERT(reporter, isIntersectionOfRects); 110 REPORTER_ASSERT(reporter, clip.getTopmostGenID() == cache.getLastClipGenID()); 112 REPORTER_ASSERT(reporter, mask == cache.getLastMask()); 116 REPORTER_ASSERT(reporter, bound == cacheBound); 155 REPORTER_ASSERT(reporter, texture1); 162 REPORTER_ASSERT(reporter, texture1->getRefCnt()); 169 REPORTER_ASSERT(reporter, texture1->getRefCnt()) [all...] |
StreamTest.cpp | 28 REPORTER_ASSERT(reporter, bytes == len); 29 REPORTER_ASSERT(reporter, !memcmp(tmp, src, len)); 34 REPORTER_ASSERT(reporter, 0 == bytes); 36 REPORTER_ASSERT(reporter, stream->isAtEnd()); 60 REPORTER_ASSERT(reporter, stream.isValid()); 70 REPORTER_ASSERT(reporter, stream.isValid()); 83 REPORTER_ASSERT(reporter, ds.write(s, 26)); 85 REPORTER_ASSERT(reporter, ds.getOffset() == 100 * 26); 90 REPORTER_ASSERT(reporter, dst[100*26] == '*'); 92 REPORTER_ASSERT(reporter, memcmp(&dst[i * 26], s, 26) == 0) [all...] |
PointTest.cpp | 21 REPORTER_ASSERT(reporter, p.asScalars() == pPtr); 22 REPORTER_ASSERT(reporter, r.asScalars() == rPtr); 33 REPORTER_ASSERT(reporter, SkScalarNearlyEqual(returned, oldLength)); 34 REPORTER_ASSERT(reporter, SkScalarNearlyEqual(newLength, SK_Scalar1)); 47 REPORTER_ASSERT(reporter, SkScalarNearlyEqual(s1, s2)); 48 REPORTER_ASSERT(reporter, SkScalarNearlyEqual(s1, expectedLength)); 96 REPORTER_ASSERT(reporter, !SkScalarIsFinite(length)); 100 REPORTER_ASSERT(reporter, pt.setLength(SK_Scalar1)); 104 REPORTER_ASSERT(reporter, SkScalarNearlyEqual(length, SK_Scalar1)); 113 REPORTER_ASSERT(reporter, 0 == SkPoint::Normalize(&pt)) [all...] |
ParsePathTest.cpp | 17 REPORTER_ASSERT(reporter, success); 20 REPORTER_ASSERT(reporter, str == str2); 23 REPORTER_ASSERT(reporter, path == path2); 45 REPORTER_ASSERT(reporter, success); 48 REPORTER_ASSERT(reporter, expectedBounds == pathBounds);
|
QuickRejectTest.cpp | 56 REPORTER_ASSERT(reporter, 0 == *dst.getAddr32(5, 5)); 60 REPORTER_ASSERT(reporter, 0xFFFFFFFF == *dst.getAddr32(5, 5)); 64 REPORTER_ASSERT(reporter, 0 == *dst.getAddr32(5, 5)); 68 REPORTER_ASSERT(reporter, 0 == *dst.getAddr32(5, 5)); 76 REPORTER_ASSERT(reporter, 0xFFFFFFFF == *dst.getAddr32(5, 5));
|
RoundRectTest.cpp | 20 REPORTER_ASSERT(reporter, rr2.isRect()); 23 REPORTER_ASSERT(reporter, rr2.isRect()); 26 REPORTER_ASSERT(reporter, rr2.isEmpty()); 30 REPORTER_ASSERT(reporter, rr2.isSimple()); 32 REPORTER_ASSERT(reporter, rr2.isRect()); 43 REPORTER_ASSERT(reporter, SkRRect::kEmpty_Type == empty.type()); 44 REPORTER_ASSERT(reporter, empty.rect().isEmpty()); 47 REPORTER_ASSERT(reporter, zeroPt == empty.radii((SkRRect::Corner) i)); 56 REPORTER_ASSERT(reporter, SkRRect::kRect_Type == rr1.type()); 57 REPORTER_ASSERT(reporter, rr1.rect() == rect) [all...] |
TileGridTest.cpp | 50 REPORTER_ASSERT(reporter, grid.tile(0,0).count() == 52 REPORTER_ASSERT(reporter, grid.tile(1,0).count() == 54 REPORTER_ASSERT(reporter, grid.tile(0,1).count() == 56 REPORTER_ASSERT(reporter, grid.tile(1,1).count() == 86 REPORTER_ASSERT(reporter, 1 == mockCanvas.fRects.count()); 87 REPORTER_ASSERT(reporter, rect1 == mockCanvas.fRects[0]); 94 REPORTER_ASSERT(reporter, 1 == mockCanvas.fRects.count()); 95 REPORTER_ASSERT(reporter, rect1 == mockCanvas.fRects[0]); 103 REPORTER_ASSERT(reporter, 2 == mockCanvas.fRects.count()); 104 REPORTER_ASSERT(reporter, rect1 == mockCanvas.fRects[0]) [all...] |
GpuBitmapCopyTest.cpp | 49 REPORTER_ASSERT(reporter, src.width() == dst.width()); 50 REPORTER_ASSERT(reporter, src.height() == dst.height()); 51 REPORTER_ASSERT(reporter, dst.config() == desiredConfig); 58 REPORTER_ASSERT(reporter, src.getGenerationID() == dst.getGenerationID()); 60 REPORTER_ASSERT(reporter, src.pixelRef() != NULL && dst.pixelRef() != NULL); 67 REPORTER_ASSERT(reporter, readBack); 71 REPORTER_ASSERT(reporter, readBack); 75 REPORTER_ASSERT(reporter, copy); 80 REPORTER_ASSERT(reporter, srcReadBack.readyToDraw() && dstReadBack.readyToDraw()); 84 REPORTER_ASSERT(reporter, srcP != dstP) [all...] |