add simplify to json tests
pathops_unittest -J dump.json
now generates both Op() and Simplify() tests and results.
Also, make json names unique. While this may not be necessary,
duplicate names may make debugging failing tests more difficult.
R=kjlubick@google.com
Bug: skia:
Change-Id: I2eed5a8141764a0ad993fb9a09c23b7d90d65048
Reviewed-on: https://skia-review.googlesource.com/146100
Commit-Queue: Cary Clark <caryclark@skia.org>
Commit-Queue: Kevin Lubick <kjlubick@google.com>
Auto-Submit: Cary Clark <caryclark@skia.org>
Reviewed-by: Kevin Lubick <kjlubick@google.com>
diff --git a/tests/PathOpsChalkboardTest.cpp b/tests/PathOpsChalkboardTest.cpp
index 88fe819..2c77da2 100644
--- a/tests/PathOpsChalkboardTest.cpp
+++ b/tests/PathOpsChalkboardTest.cpp
@@ -10,6 +10,8 @@
#define TEST(name) { name, #name }
+static int gTestNo = 0;
+
static void chalkboard(skiatest::Reporter* reporter, uint64_t testlines) {
SkPath path;
path.setFillType((SkPath::FillType) 0);
@@ -81,8 +83,9 @@
if (testlines & (1LL << i++)) path.cubicTo(SkBits2Float(0x4470e8f6), SkBits2Float(0x439c4e35), SkBits2Float(0x4470ee98), SkBits2Float(0x439c5333), SkBits2Float(0x4470eed9), SkBits2Float(0x439c1ac1)); // 963.64f, 312.611f, 963.728f, 312.65f, 963.732f, 312.209f
SkASSERT(64 == i);
path.close();
-
-testSimplify(reporter, path, "chalkboard");
+SkString testName;
+testName.printf("chalkboard%d", ++gTestNo);
+testSimplify(reporter, path, testName.c_str());
}
static void testChalkboard(PathOpsThreadState* data) {