OLD | NEW |
1 #include "DMTestTask.h" | 1 #include "DMTestTask.h" |
2 #include "DMUtil.h" | 2 #include "DMUtil.h" |
3 #include "SkCommandLineFlags.h" | 3 #include "SkCommandLineFlags.h" |
| 4 #include "SkCommonFlags.h" |
4 | 5 |
5 // When PathOps threaded tests get going, they're briefly a big consumer of lots
of RAM. | 6 // When PathOps threaded tests get going, they're briefly a big consumer of lots
of RAM. |
6 // We disable the internal threading there by default on 32-bit builds. | 7 // We disable the internal threading there by default on 32-bit builds. |
7 static const bool is32Bit = sizeof(void*) == 4; | 8 static const bool is32Bit = sizeof(void*) == 4; |
8 | 9 |
9 DEFINE_bool2(pathOpsExtended, x, false, "Run extended pathOps tests."); | 10 DEFINE_bool2(pathOpsExtended, x, false, "Run extended pathOps tests."); |
10 DEFINE_bool2(pathOpsSingleThread, z, is32Bit, "Disallow pathOps tests from using
threads."); | 11 DEFINE_bool2(pathOpsSingleThread, z, is32Bit, "Disallow pathOps tests from using
threads."); |
11 DEFINE_bool2(pathOpsVerbose, V, false, "Tell pathOps tests to be verbose.")
; | |
12 | 12 |
13 namespace DM { | 13 namespace DM { |
14 | 14 |
15 bool TestReporter::allowExtendedTest() const { return FLAGS_pathOpsExtended; } | 15 bool TestReporter::allowExtendedTest() const { return FLAGS_pathOpsExtended; } |
16 bool TestReporter::allowThreaded() const { return !FLAGS_pathOpsSingleThread
; } | 16 bool TestReporter::allowThreaded() const { return !FLAGS_pathOpsSingleThread
; } |
17 bool TestReporter::verbose() const { return FLAGS_pathOpsVerbose; } | 17 bool TestReporter::verbose() const { return FLAGS_veryVerbose; } |
18 | 18 |
19 static SkString test_name(const char* name) { | 19 static SkString test_name(const char* name) { |
20 SkString result("test "); | 20 SkString result("test "); |
21 result.append(name); | 21 result.append(name); |
22 return result; | 22 return result; |
23 } | 23 } |
24 | 24 |
25 CpuTestTask::CpuTestTask(Reporter* reporter, | 25 CpuTestTask::CpuTestTask(Reporter* reporter, |
26 TaskRunner* taskRunner, | 26 TaskRunner* taskRunner, |
27 skiatest::TestRegistry::Factory factory) | 27 skiatest::TestRegistry::Factory factory) |
(...skipping 24 matching lines...) Expand all Loading... |
52 if (!fTest->passed()) { | 52 if (!fTest->passed()) { |
53 this->fail(fTestReporter.failure()); | 53 this->fail(fTestReporter.failure()); |
54 } | 54 } |
55 } | 55 } |
56 | 56 |
57 bool GpuTestTask::shouldSkip() const { | 57 bool GpuTestTask::shouldSkip() const { |
58 return kGPUDisabled; | 58 return kGPUDisabled; |
59 } | 59 } |
60 | 60 |
61 } // namespace DM | 61 } // namespace DM |
OLD | NEW |