From e3a4e993ef79788d5ee807b10ff588e9c46bac6d Mon Sep 17 00:00:00 2001 From: caryclark Date: Wed, 28 Sep 2016 09:22:17 -0700 Subject: fix cubic linear test Check to see if the line between end points is degenerate before measuring control points. Also, add test case for a bug to see if it shows up on any platform. TBR=reed@google.com BUG=skia:5169, skia:5240 GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2375053002 Review-Url: https://codereview.chromium.org/2375053002 --- tests/PathOpsSimplifyFailTest.cpp | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) (limited to 'tests/PathOpsSimplifyFailTest.cpp') diff --git a/tests/PathOpsSimplifyFailTest.cpp b/tests/PathOpsSimplifyFailTest.cpp index 359b12592b..fa168d9520 100644 --- a/tests/PathOpsSimplifyFailTest.cpp +++ b/tests/PathOpsSimplifyFailTest.cpp @@ -87,10 +87,8 @@ static void dontFailOne(skiatest::Reporter* reporter, int index) { SkPath result; result.setFillType(SkPath::kWinding_FillType); bool success = Simplify(path, &result); - if (index != 17 && index != 31 && index != 38) { // cubic fails to chop in two without creating NaNs - REPORTER_ASSERT(reporter, success); - REPORTER_ASSERT(reporter, result.getFillType() != SkPath::kWinding_FillType); - } + REPORTER_ASSERT(reporter, success); + REPORTER_ASSERT(reporter, result.getFillType() != SkPath::kWinding_FillType); reporter->bumpTestCount(); } -- cgit v1.2.3