| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright 2011 Google Inc. | 2 * Copyright 2011 Google Inc. |
| 3 * | 3 * |
| 4 * Use of this source code is governed by a BSD-style license that can be | 4 * Use of this source code is governed by a BSD-style license that can be |
| 5 * found in the LICENSE file. | 5 * found in the LICENSE file. |
| 6 */ | 6 */ |
| 7 | 7 |
| 8 #include "Test.h" | 8 #include "Test.h" |
| 9 #include "TestClassDef.h" |
| 9 #include "SkPath.h" | 10 #include "SkPath.h" |
| 10 #include "SkCanvas.h" | 11 #include "SkCanvas.h" |
| 11 | 12 |
| 12 static void appendStr(SkString* str, const SkPaint& paint) { | 13 static void appendStr(SkString* str, const SkPaint& paint) { |
| 13 str->appendf(" style[%d] cap[%d] join[%d] antialias[%d]", | 14 str->appendf(" style[%d] cap[%d] join[%d] antialias[%d]", |
| 14 paint.getStyle(), paint.getStrokeCap(), | 15 paint.getStyle(), paint.getStrokeCap(), |
| 15 paint.getStrokeJoin(), paint.isAntiAlias()); | 16 paint.getStrokeJoin(), paint.isAntiAlias()); |
| 16 } | 17 } |
| 17 | 18 |
| 18 static void appendStr(SkString* str, const SkPath& path) { | 19 static void appendStr(SkString* str, const SkPath& path) { |
| (...skipping 122 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 141 } | 142 } |
| 142 for (size_t fill = 0; fill < SK_ARRAY_COUNT(gFills); ++fill) { | 143 for (size_t fill = 0; fill < SK_ARRAY_COUNT(gFills); ++fill) { |
| 143 path.setFillType(gFills[fill]); | 144 path.setFillType(gFills[fill]); |
| 144 bool shouldDraw = path.isInverseFillType(); | 145 bool shouldDraw = path.isInverseFillType(); |
| 145 iter_paint(reporter, path, shouldDraw); | 146 iter_paint(reporter, path, shouldDraw); |
| 146 } | 147 } |
| 147 } | 148 } |
| 148 } | 149 } |
| 149 } | 150 } |
| 150 | 151 |
| 151 static void TestEmptyPath(skiatest::Reporter* reporter) { | 152 DEF_TEST(EmptyPath, reporter) { |
| 152 test_emptydrawing(reporter); | 153 test_emptydrawing(reporter); |
| 153 } | 154 } |
| 154 | |
| 155 #include "TestClassDef.h" | |
| 156 DEFINE_TESTCLASS("EmptyPath", TestEmptyPathClass, TestEmptyPath) | |
| OLD | NEW |