aboutsummaryrefslogtreecommitdiffhomepage
path: root/tests/PathOpsSkpClipTest.cpp
diff options
context:
space:
mode:
authorGravatar halcanary <halcanary@google.com>2015-08-26 13:07:48 -0700
committerGravatar Commit bot <commit-bot@chromium.org>2015-08-26 13:07:49 -0700
commit385fe4d4b62d7d1dd76116dd570df3290a2f487b (patch)
tree53d982ff238828331e86acd44071a44162a8688c /tests/PathOpsSkpClipTest.cpp
parent5015176adf046ef906a2313b6e6b64b72cc84898 (diff)
Style Change: SkNEW->new; SkDELETE->delete
Diffstat (limited to 'tests/PathOpsSkpClipTest.cpp')
-rw-r--r--[-rwxr-xr-x]tests/PathOpsSkpClipTest.cpp36
1 files changed, 17 insertions, 19 deletions
diff --git a/tests/PathOpsSkpClipTest.cpp b/tests/PathOpsSkpClipTest.cpp
index 95421fca30..de4f48c586 100755..100644
--- a/tests/PathOpsSkpClipTest.cpp
+++ b/tests/PathOpsSkpClipTest.cpp
@@ -300,7 +300,7 @@ public:
TestRunner::~TestRunner() {
for (int index = 0; index < fRunnables.count(); index++) {
- SkDELETE(fRunnables[index]);
+ delete fRunnables[index];
}
}
@@ -799,8 +799,8 @@ static void encodeFound(TestState& state) {
if (!filename.endsWith(".skp")) {
filename.append(".skp");
}
- *testRunner.fRunnables.append() = SkNEW_ARGS(TestRunnableEncode,
- (&testSkpClipEncode, result.fDirNo, filename.c_str(), &testRunner));
+ *testRunner.fRunnables.append() = new TestRunnableEncode(&testSkpClipEncode, result.fDirNo,
+ filename.c_str(), &testRunner);
}
testRunner.render();
}
@@ -823,18 +823,17 @@ private:
typedef SkTRegistry<Test*(*)(void*)> TestRegistry;
-#define DEF_TEST(name) \
- static void test_##name(); \
- class name##Class : public Test { \
- public: \
- static Test* Factory(void*) { return SkNEW(name##Class); } \
- protected: \
- void onGetName(SkString* name) override { \
- name->set(#name); \
- } \
- void onRun() override { test_##name(); } \
- }; \
- static TestRegistry gReg_##name##Class(name##Class::Factory); \
+#define DEF_TEST(name) \
+ static void test_##name(); \
+ class name##Class : public Test { \
+ public: \
+ static Test* Factory(void*) { return new name##Class; } \
+ \
+ protected: \
+ void onGetName(SkString* name) override { name->set(#name); } \
+ void onRun() override { test_##name(); } \
+ }; \
+ static TestRegistry gReg_##name##Class(name##Class::Factory); \
static void test_##name()
DEF_TEST(PathOpsSkpClip) {
@@ -868,8 +867,7 @@ DEF_TEST(PathOpsSkpClipThreaded) {
int dirNo;
gDirs.reset();
while ((dirNo = gDirs.next()) > 0) {
- *testRunner.fRunnables.append() = SkNEW_ARGS(TestRunnableDir,
- (&testSkpClipMain, dirNo, &testRunner));
+ *testRunner.fRunnables.append() = new TestRunnableDir(&testSkpClipMain, dirNo, &testRunner);
}
testRunner.render();
TestState state;
@@ -934,8 +932,8 @@ DEF_TEST(PathOpsSkpClipUberThreaded) {
int count = sorted.get()[dirNo - firstDirNo].count();
if (SkTSearch<SortByName, Less>(sorted.get()[dirNo - firstDirNo].begin(),
count, &name, sizeof(&name)) < 0) {
- *testRunner.fRunnables.append() = SkNEW_ARGS(TestRunnableFile,
- (&testSkpClip, dirNo, filename.c_str(), &testRunner));
+ *testRunner.fRunnables.append() = new TestRunnableFile(
+ &testSkpClip, dirNo, filename.c_str(), &testRunner);
}
}
checkEarlyExit: