aboutsummaryrefslogtreecommitdiffhomepage
path: root/tests
diff options
context:
space:
mode:
authorGravatar reed <reed@chromium.org>2015-02-10 08:46:22 -0800
committerGravatar Commit bot <commit-bot@chromium.org>2015-02-10 08:46:22 -0800
commit454fa71cc31bf45c14e4c0b25502d5332d76c51c (patch)
tree54f5bc37eaa2ba3cf69b1f5c386e7881b3f03885 /tests
parent88f0a99fd48cfb30ca5596182f8932d76cd76f17 (diff)
check for nonfinites in rrects
Diffstat (limited to 'tests')
-rw-r--r--tests/PathTest.cpp6
1 files changed, 4 insertions, 2 deletions
diff --git a/tests/PathTest.cpp b/tests/PathTest.cpp
index a852bf0d10..d1c28ec0fb 100644
--- a/tests/PathTest.cpp
+++ b/tests/PathTest.cpp
@@ -3113,10 +3113,12 @@ static void test_rrect(skiatest::Reporter* reporter) {
rr.setRectRadii(largeR, radii);
p.addRRect(rr);
test_rrect_convexity_is_unknown(reporter, &p, SkPath::kCW_Direction);
+
+ // we check for non-finites
SkRect infR = {0, 0, SK_ScalarMax, SK_ScalarInfinity};
rr.setRectRadii(infR, radii);
- p.addRRect(rr);
- test_rrect_convexity_is_unknown(reporter, &p, SkPath::kCW_Direction);
+ REPORTER_ASSERT(reporter, rr.isEmpty());
+
SkRect tinyR = {0, 0, 1e-9f, 1e-9f};
p.addRoundRect(tinyR, 5e-11f, 5e-11f);
test_rrect_is_convex(reporter, &p, SkPath::kCW_Direction);