Lines Matching refs:REPORTER_ASSERT
45 REPORTER_ASSERT(reporter, aVal == bVal && aValI == aValI); in are_equal()
48 REPORTER_ASSERT(reporter, foundZeroSignDiff); in are_equal()
59 REPORTER_ASSERT(reporter, aVal == bVal && aValI == bValI); in are_equal()
62 REPORTER_ASSERT(reporter, foundNaN); in are_equal()
80 REPORTER_ASSERT(reporter, buffer[0] == a); in assert9()
81 REPORTER_ASSERT(reporter, buffer[1] == b); in assert9()
82 REPORTER_ASSERT(reporter, buffer[2] == c); in assert9()
83 REPORTER_ASSERT(reporter, buffer[3] == d); in assert9()
84 REPORTER_ASSERT(reporter, buffer[4] == e); in assert9()
85 REPORTER_ASSERT(reporter, buffer[5] == f); in assert9()
86 REPORTER_ASSERT(reporter, buffer[6] == g); in assert9()
87 REPORTER_ASSERT(reporter, buffer[7] == h); in assert9()
88 REPORTER_ASSERT(reporter, buffer[8] == i); in assert9()
108 REPORTER_ASSERT(reporter, !m.isIdentity()); in test_set9()
110 REPORTER_ASSERT(reporter, m.isIdentity()); in test_set9()
120 REPORTER_ASSERT(reporter, SkMatrix::kIdentity_Mask == matrix.getType()); in test_matrix_recttorect()
121 REPORTER_ASSERT(reporter, matrix.rectStaysRect()); in test_matrix_recttorect()
125 REPORTER_ASSERT(reporter, SkMatrix::kTranslate_Mask == matrix.getType()); in test_matrix_recttorect()
126 REPORTER_ASSERT(reporter, matrix.rectStaysRect()); in test_matrix_recttorect()
130 REPORTER_ASSERT(reporter, in test_matrix_recttorect()
132 REPORTER_ASSERT(reporter, matrix.rectStaysRect()); in test_matrix_recttorect()
137 REPORTER_ASSERT(reporter, SkMatrix::kScale_Mask == matrix.getType()); in test_matrix_recttorect()
138 REPORTER_ASSERT(reporter, matrix.rectStaysRect()); in test_matrix_recttorect()
147 REPORTER_ASSERT(reporter, size1 == size2); in test_flatten()
148 REPORTER_ASSERT(reporter, size1 <= SkMatrix::kMaxFlattenSize); in test_flatten()
152 REPORTER_ASSERT(reporter, size1 == size3); in test_flatten()
153 REPORTER_ASSERT(reporter, are_equal(reporter, m, m2)); in test_flatten()
157 REPORTER_ASSERT(reporter, size1 == size3); in test_flatten()
158 REPORTER_ASSERT(reporter, memcmp(buffer, buffer2, size1) == 0); in test_flatten()
167 REPORTER_ASSERT(reporter, SK_Scalar1 == identity.getMinScale()); in test_matrix_min_max_scale()
168 REPORTER_ASSERT(reporter, SK_Scalar1 == identity.getMaxScale()); in test_matrix_min_max_scale()
170 REPORTER_ASSERT(reporter, success && SK_Scalar1 == scales[0] && SK_Scalar1 == scales[1]); in test_matrix_min_max_scale()
174 REPORTER_ASSERT(reporter, SK_Scalar1 * 2 == scale.getMinScale()); in test_matrix_min_max_scale()
175 REPORTER_ASSERT(reporter, SK_Scalar1 * 4 == scale.getMaxScale()); in test_matrix_min_max_scale()
177 … REPORTER_ASSERT(reporter, success && SK_Scalar1 * 2 == scales[0] && SK_Scalar1 * 4 == scales[1]); in test_matrix_min_max_scale()
182 REPORTER_ASSERT(reporter, SK_Scalar1 / 4 == rot90Scale.getMinScale()); in test_matrix_min_max_scale()
183 REPORTER_ASSERT(reporter, SK_Scalar1 / 2 == rot90Scale.getMaxScale()); in test_matrix_min_max_scale()
185 … REPORTER_ASSERT(reporter, success && SK_Scalar1 / 4 == scales[0] && SK_Scalar1 / 2 == scales[1]); in test_matrix_min_max_scale()
189 …REPORTER_ASSERT(reporter, SkScalarNearlyEqual(SK_Scalar1, rotate.getMinScale(), SK_ScalarNearlyZer… in test_matrix_min_max_scale()
190 …REPORTER_ASSERT(reporter, SkScalarNearlyEqual(SK_Scalar1, rotate.getMaxScale(), SK_ScalarNearlyZer… in test_matrix_min_max_scale()
192 REPORTER_ASSERT(reporter, success); in test_matrix_min_max_scale()
193 REPORTER_ASSERT(reporter, SkScalarNearlyEqual(SK_Scalar1, scales[0], SK_ScalarNearlyZero)); in test_matrix_min_max_scale()
194 REPORTER_ASSERT(reporter, SkScalarNearlyEqual(SK_Scalar1, scales[1], SK_ScalarNearlyZero)); in test_matrix_min_max_scale()
198 REPORTER_ASSERT(reporter, SK_Scalar1 == translate.getMinScale()); in test_matrix_min_max_scale()
199 REPORTER_ASSERT(reporter, SK_Scalar1 == translate.getMaxScale()); in test_matrix_min_max_scale()
201 REPORTER_ASSERT(reporter, success && SK_Scalar1 == scales[0] && SK_Scalar1 == scales[1]); in test_matrix_min_max_scale()
206 REPORTER_ASSERT(reporter, -SK_Scalar1 == perspX.getMinScale()); in test_matrix_min_max_scale()
207 REPORTER_ASSERT(reporter, -SK_Scalar1 == perspX.getMaxScale()); in test_matrix_min_max_scale()
212 …REPORTER_ASSERT(reporter, !success && -5 * SK_Scalar1 == scales[0] && -5 * SK_Scalar1 == scales[1… in test_matrix_min_max_scale()
217 REPORTER_ASSERT(reporter, -SK_Scalar1 == perspY.getMinScale()); in test_matrix_min_max_scale()
218 REPORTER_ASSERT(reporter, -SK_Scalar1 == perspY.getMaxScale()); in test_matrix_min_max_scale()
222 …REPORTER_ASSERT(reporter, !success && -5 * SK_Scalar1 == scales[0] && -5 * SK_Scalar1 == scales[1… in test_matrix_min_max_scale()
230 REPORTER_ASSERT(reporter, invertable); in test_matrix_min_max_scale()
243 REPORTER_ASSERT(reporter, (minScale < 0) == (maxScale < 0)); in test_matrix_min_max_scale()
244 REPORTER_ASSERT(reporter, (maxScale < 0) == mat.hasPerspective()); in test_matrix_min_max_scale()
248 REPORTER_ASSERT(reporter, success == !mat.hasPerspective()); in test_matrix_min_max_scale()
249 REPORTER_ASSERT(reporter, !success || (scales[0] == minScale && scales[1] == maxScale)); in test_matrix_min_max_scale()
273 REPORTER_ASSERT(reporter, d / maxScale < gVectorScaleTol); in test_matrix_min_max_scale()
274 REPORTER_ASSERT(reporter, minScale / d < gVectorScaleTol); in test_matrix_min_max_scale()
282 REPORTER_ASSERT(reporter, max / maxScale >= gCloseScaleTol); in test_matrix_min_max_scale()
283 REPORTER_ASSERT(reporter, minScale / min >= gCloseScaleTol); in test_matrix_min_max_scale()
292 REPORTER_ASSERT(reporter, mat.isSimilarity()); in test_matrix_preserve_shape()
293 REPORTER_ASSERT(reporter, mat.preservesRightAngles()); in test_matrix_preserve_shape()
298 REPORTER_ASSERT(reporter, mat.isSimilarity()); in test_matrix_preserve_shape()
299 REPORTER_ASSERT(reporter, mat.preservesRightAngles()); in test_matrix_preserve_shape()
304 REPORTER_ASSERT(reporter, mat.isSimilarity()); in test_matrix_preserve_shape()
305 REPORTER_ASSERT(reporter, mat.preservesRightAngles()); in test_matrix_preserve_shape()
310 REPORTER_ASSERT(reporter, mat.isSimilarity()); in test_matrix_preserve_shape()
311 REPORTER_ASSERT(reporter, mat.preservesRightAngles()); in test_matrix_preserve_shape()
316 REPORTER_ASSERT(reporter, !mat.isSimilarity()); in test_matrix_preserve_shape()
317 REPORTER_ASSERT(reporter, mat.preservesRightAngles()); in test_matrix_preserve_shape()
323 REPORTER_ASSERT(reporter, mat.isSimilarity()); in test_matrix_preserve_shape()
324 REPORTER_ASSERT(reporter, mat.preservesRightAngles()); in test_matrix_preserve_shape()
330 REPORTER_ASSERT(reporter, !mat.isSimilarity()); in test_matrix_preserve_shape()
331 REPORTER_ASSERT(reporter, mat.preservesRightAngles()); in test_matrix_preserve_shape()
336 REPORTER_ASSERT(reporter, !mat.isSimilarity()); in test_matrix_preserve_shape()
337 REPORTER_ASSERT(reporter, !mat.preservesRightAngles()); in test_matrix_preserve_shape()
342 REPORTER_ASSERT(reporter, !mat.isSimilarity()); in test_matrix_preserve_shape()
343 REPORTER_ASSERT(reporter, !mat.preservesRightAngles()); in test_matrix_preserve_shape()
349 REPORTER_ASSERT(reporter, !mat.isSimilarity()); in test_matrix_preserve_shape()
350 REPORTER_ASSERT(reporter, !mat.preservesRightAngles()); in test_matrix_preserve_shape()
356 REPORTER_ASSERT(reporter, !mat.isSimilarity()); in test_matrix_preserve_shape()
357 REPORTER_ASSERT(reporter, !mat.preservesRightAngles()); in test_matrix_preserve_shape()
362 REPORTER_ASSERT(reporter, !mat.isSimilarity()); in test_matrix_preserve_shape()
363 REPORTER_ASSERT(reporter, !mat.preservesRightAngles()); in test_matrix_preserve_shape()
368 REPORTER_ASSERT(reporter, !mat.isSimilarity()); in test_matrix_preserve_shape()
369 REPORTER_ASSERT(reporter, !mat.preservesRightAngles()); in test_matrix_preserve_shape()
375 REPORTER_ASSERT(reporter, mat.isSimilarity()); in test_matrix_preserve_shape()
376 REPORTER_ASSERT(reporter, mat.preservesRightAngles()); in test_matrix_preserve_shape()
384 REPORTER_ASSERT(reporter, mat.isSimilarity()); in test_matrix_preserve_shape()
385 REPORTER_ASSERT(reporter, mat.preservesRightAngles()); in test_matrix_preserve_shape()
391 REPORTER_ASSERT(reporter, mat.isSimilarity()); in test_matrix_preserve_shape()
392 REPORTER_ASSERT(reporter, mat.preservesRightAngles()); in test_matrix_preserve_shape()
398 REPORTER_ASSERT(reporter, mat.isSimilarity()); in test_matrix_preserve_shape()
399 REPORTER_ASSERT(reporter, mat.preservesRightAngles()); in test_matrix_preserve_shape()
405 REPORTER_ASSERT(reporter, !mat.isSimilarity()); in test_matrix_preserve_shape()
406 REPORTER_ASSERT(reporter, !mat.preservesRightAngles()); in test_matrix_preserve_shape()
412 REPORTER_ASSERT(reporter, !mat.isSimilarity()); in test_matrix_preserve_shape()
413 REPORTER_ASSERT(reporter, mat.preservesRightAngles()); in test_matrix_preserve_shape()
417 REPORTER_ASSERT(reporter, !mat.isSimilarity()); in test_matrix_preserve_shape()
418 REPORTER_ASSERT(reporter, !mat.preservesRightAngles()); in test_matrix_preserve_shape()
423 REPORTER_ASSERT(reporter, !mat.isSimilarity()); in test_matrix_preserve_shape()
424 REPORTER_ASSERT(reporter, !mat.preservesRightAngles()); in test_matrix_preserve_shape()
430 REPORTER_ASSERT(reporter, mat.isSimilarity()); in test_matrix_preserve_shape()
431 REPORTER_ASSERT(reporter, mat.preservesRightAngles()); in test_matrix_preserve_shape()
437 REPORTER_ASSERT(reporter, mat.isSimilarity()); in test_matrix_preserve_shape()
438 REPORTER_ASSERT(reporter, mat.preservesRightAngles()); in test_matrix_preserve_shape()
497 REPORTER_ASSERT(reporter, SkDecomposeUpper2x2(mat, &rotation1, &scale, &rotation2)); in test_matrix_decomposition()
498 REPORTER_ASSERT(reporter, check_matrix_recomposition(mat, rotation1, scale, rotation2)); in test_matrix_decomposition()
500 REPORTER_ASSERT(reporter, SkDecomposeUpper2x2(mat, NULL, NULL, NULL)); in test_matrix_decomposition()
504 REPORTER_ASSERT(reporter, SkDecomposeUpper2x2(mat, &rotation1, &scale, &rotation2)); in test_matrix_decomposition()
505 REPORTER_ASSERT(reporter, check_matrix_recomposition(mat, rotation1, scale, rotation2)); in test_matrix_decomposition()
509 REPORTER_ASSERT(reporter, SkDecomposeUpper2x2(mat, &rotation1, &scale, &rotation2)); in test_matrix_decomposition()
510 REPORTER_ASSERT(reporter, check_matrix_recomposition(mat, rotation1, scale, rotation2)); in test_matrix_decomposition()
514 REPORTER_ASSERT(reporter, SkDecomposeUpper2x2(mat, &rotation1, &scale, &rotation2)); in test_matrix_decomposition()
515 REPORTER_ASSERT(reporter, check_matrix_recomposition(mat, rotation1, scale, rotation2)); in test_matrix_decomposition()
520 REPORTER_ASSERT(reporter, SkDecomposeUpper2x2(mat, &rotation1, &scale, &rotation2)); in test_matrix_decomposition()
521 REPORTER_ASSERT(reporter, check_matrix_recomposition(mat, rotation1, scale, rotation2)); in test_matrix_decomposition()
526 REPORTER_ASSERT(reporter, SkDecomposeUpper2x2(mat, &rotation1, &scale, &rotation2)); in test_matrix_decomposition()
527 REPORTER_ASSERT(reporter, check_matrix_recomposition(mat, rotation1, scale, rotation2)); in test_matrix_decomposition()
532 REPORTER_ASSERT(reporter, SkDecomposeUpper2x2(mat, &rotation1, &scale, &rotation2)); in test_matrix_decomposition()
533 REPORTER_ASSERT(reporter, check_matrix_recomposition(mat, rotation1, scale, rotation2)); in test_matrix_decomposition()
538 REPORTER_ASSERT(reporter, SkDecomposeUpper2x2(mat, &rotation1, &scale, &rotation2)); in test_matrix_decomposition()
539 REPORTER_ASSERT(reporter, check_matrix_recomposition(mat, rotation1, scale, rotation2)); in test_matrix_decomposition()
544 REPORTER_ASSERT(reporter, SkDecomposeUpper2x2(mat, &rotation1, &scale, &rotation2)); in test_matrix_decomposition()
545 REPORTER_ASSERT(reporter, check_matrix_recomposition(mat, rotation1, scale, rotation2)); in test_matrix_decomposition()
550 REPORTER_ASSERT(reporter, SkDecomposeUpper2x2(mat, &rotation1, &scale, &rotation2)); in test_matrix_decomposition()
551 REPORTER_ASSERT(reporter, check_matrix_recomposition(mat, rotation1, scale, rotation2)); in test_matrix_decomposition()
556 REPORTER_ASSERT(reporter, SkDecomposeUpper2x2(mat, &rotation1, &scale, &rotation2)); in test_matrix_decomposition()
557 REPORTER_ASSERT(reporter, check_matrix_recomposition(mat, rotation1, scale, rotation2)); in test_matrix_decomposition()
562 REPORTER_ASSERT(reporter, SkDecomposeUpper2x2(mat, &rotation1, &scale, &rotation2)); in test_matrix_decomposition()
563 REPORTER_ASSERT(reporter, check_matrix_recomposition(mat, rotation1, scale, rotation2)); in test_matrix_decomposition()
569 REPORTER_ASSERT(reporter, SkDecomposeUpper2x2(mat, &rotation1, &scale, &rotation2)); in test_matrix_decomposition()
570 REPORTER_ASSERT(reporter, check_matrix_recomposition(mat, rotation1, scale, rotation2)); in test_matrix_decomposition()
576 REPORTER_ASSERT(reporter, SkDecomposeUpper2x2(mat, &rotation1, &scale, &rotation2)); in test_matrix_decomposition()
577 REPORTER_ASSERT(reporter, check_matrix_recomposition(mat, rotation1, scale, rotation2)); in test_matrix_decomposition()
583 REPORTER_ASSERT(reporter, SkDecomposeUpper2x2(mat, &rotation1, &scale, &rotation2)); in test_matrix_decomposition()
584 REPORTER_ASSERT(reporter, check_matrix_recomposition(mat, rotation1, scale, rotation2)); in test_matrix_decomposition()
598 REPORTER_ASSERT(reporter, check_matrix_recomposition(mat, rotation1, scale, rotation2)); in test_matrix_decomposition()
603 REPORTER_ASSERT(reporter, SkScalarNearlyZero(perpdot)); in test_matrix_decomposition()
609 REPORTER_ASSERT(reporter, SkDecomposeUpper2x2(mat, &rotation1, &scale, &rotation2)); in test_matrix_decomposition()
610 REPORTER_ASSERT(reporter, check_matrix_recomposition(mat, rotation1, scale, rotation2)); in test_matrix_decomposition()
616 REPORTER_ASSERT(reporter, SkDecomposeUpper2x2(mat, &rotation1, &scale, &rotation2)); in test_matrix_decomposition()
617 REPORTER_ASSERT(reporter, check_matrix_recomposition(mat, rotation1, scale, rotation2)); in test_matrix_decomposition()
623 REPORTER_ASSERT(reporter, !SkDecomposeUpper2x2(mat, &rotation1, &scale, &rotation2)); in test_matrix_decomposition()
626 REPORTER_ASSERT(reporter, !SkDecomposeUpper2x2(mat, &rotation1, &scale, &rotation2)); in test_matrix_decomposition()
633 REPORTER_ASSERT(reporter, !SkDecomposeUpper2x2(mat, &rotation1, &scale, &rotation2)); in test_matrix_decomposition()
688 REPORTER_ASSERT(reporter, scalar_array_nearly_equal_relative(randTriples, dst, kTripleCount*3)); in test_matrix_homogeneous()
698 REPORTER_ASSERT(reporter, scalar_array_nearly_equal_relative(&dst[i*3], zeros, 3)); in test_matrix_homogeneous()
708 REPORTER_ASSERT(reporter, scalar_array_nearly_equal_relative(dst, zeros, 3)); in test_matrix_homogeneous()
726 REPORTER_ASSERT(reporter, SkScalarNearlyEqual(dst[0], pnt.fX)); in test_matrix_homogeneous()
727 REPORTER_ASSERT(reporter, SkScalarNearlyEqual(dst[1], pnt.fY)); in test_matrix_homogeneous()
728 REPORTER_ASSERT(reporter, SkScalarNearlyEqual(dst[2], SK_Scalar1)); in test_matrix_homogeneous()
740 REPORTER_ASSERT(reporter, SkScalarNearlyEqual(dst[0], pnt.fX)); in test_matrix_homogeneous()
741 REPORTER_ASSERT(reporter, SkScalarNearlyEqual(dst[1], pnt.fY)); in test_matrix_homogeneous()
742 REPORTER_ASSERT(reporter, SkScalarNearlyEqual(dst[2], SK_Scalar1)); in test_matrix_homogeneous()
756 REPORTER_ASSERT(reporter, SkScalarNearlyEqual(dst[0], pnt.fX)); in test_matrix_homogeneous()
757 REPORTER_ASSERT(reporter, SkScalarNearlyEqual(dst[1], pnt.fY)); in test_matrix_homogeneous()
758 REPORTER_ASSERT(reporter, SkScalarNearlyEqual(dst[2], SK_Scalar1)); in test_matrix_homogeneous()
767 REPORTER_ASSERT(reporter, naive_homogeneous_mapping(mats[i], &randTriples[j*3], dst)); in test_matrix_homogeneous()
792 REPORTER_ASSERT(reporter, check_decompScale(m)); in test_decompScale()
794 REPORTER_ASSERT(reporter, check_decompScale(m)); in test_decompScale()
796 REPORTER_ASSERT(reporter, check_decompScale(m)); in test_decompScale()
799 REPORTER_ASSERT(reporter, !check_decompScale(m)); in test_decompScale()
807 REPORTER_ASSERT(reporter, mat.invert(&inverse)); in DEF_TEST()
809 REPORTER_ASSERT(reporter, is_identity(iden1)); in DEF_TEST()
812 REPORTER_ASSERT(reporter, mat.invert(&inverse)); in DEF_TEST()
814 REPORTER_ASSERT(reporter, is_identity(iden1)); in DEF_TEST()
818 REPORTER_ASSERT(reporter, mat.invert(&inverse)); in DEF_TEST()
820 REPORTER_ASSERT(reporter, is_identity(iden1)); in DEF_TEST()
825 REPORTER_ASSERT(reporter, mat.invert(NULL)); in DEF_TEST()
826 REPORTER_ASSERT(reporter, mat.invert(&inverse)); in DEF_TEST()
828 REPORTER_ASSERT(reporter, is_identity(iden1)); in DEF_TEST()
830 REPORTER_ASSERT(reporter, is_identity(iden2)); in DEF_TEST()
835 REPORTER_ASSERT(reporter, !mat.invert(NULL)); in DEF_TEST()
836 REPORTER_ASSERT(reporter, !mat.invert(&inverse)); in DEF_TEST()
838 REPORTER_ASSERT(reporter, !mat.invert(NULL)); in DEF_TEST()
839 REPORTER_ASSERT(reporter, !mat.invert(&inverse)); in DEF_TEST()
874 REPORTER_ASSERT(reporter, in DEF_TEST()
887 REPORTER_ASSERT(reporter, mat.asAffine(affine)); in DEF_TEST()
890 REPORTER_ASSERT(reporter, affineEqual(ScaleX)); in DEF_TEST()
891 REPORTER_ASSERT(reporter, affineEqual(SkewY)); in DEF_TEST()
892 REPORTER_ASSERT(reporter, affineEqual(SkewX)); in DEF_TEST()
893 REPORTER_ASSERT(reporter, affineEqual(ScaleY)); in DEF_TEST()
894 REPORTER_ASSERT(reporter, affineEqual(TransX)); in DEF_TEST()
895 REPORTER_ASSERT(reporter, affineEqual(TransY)); in DEF_TEST()
899 REPORTER_ASSERT(reporter, !mat.asAffine(affine)); in DEF_TEST()
906 REPORTER_ASSERT(reporter, are_equal(reporter, mat, mat2)); in DEF_TEST()
912 REPORTER_ASSERT(reporter, !are_equal(reporter, mat, mat2)); in DEF_TEST()
934 REPORTER_ASSERT(r, expected == SkMatrix::Concat(a, b)); in DEF_TEST()