diff options
author | 2015-06-04 14:15:33 -0700 | |
---|---|---|
committer | 2015-06-04 14:15:33 -0700 | |
commit | 821e10ed41394adbdcd989ea9b32b059042cf0e9 (patch) | |
tree | f60284be3c0fdddda391b66bad6afa25db11f9d0 /dm | |
parent | ad7ae6c821c530dd6cb54b0e8931ba8b10e8d87d (diff) |
Add prelog flag to DM
Review URL: https://codereview.chromium.org/1158263004
Diffstat (limited to 'dm')
-rw-r--r-- | dm/DM.cpp | 7 |
1 files changed, 7 insertions, 0 deletions
@@ -48,6 +48,7 @@ DEFINE_string(uninterestingHashesFile, "", DEFINE_int32(shards, 1, "We're splitting source data into this many shards."); DEFINE_int32(shard, 0, "Which shard do I run?"); +DEFINE_bool2(pre_log, p, false, "Log before running each test. May be incomprehensible when threading"); __SK_FORCE_IMAGE_DECODER_LINKING; using namespace DM; @@ -466,6 +467,9 @@ struct Task { if (!FLAGS_dryRun && whyBlacklisted.isEmpty()) { SkBitmap bitmap; SkDynamicMemoryWStream stream; + if (FLAGS_pre_log) { + SkDebugf("\nRunning %s->%s", name.c_str(), task->sink.tag); + } start(task->sink.tag, task->src.tag, task->src.options, name.c_str()); Error err = task->sink->draw(*task->src, &bitmap, &stream, &log); if (!err.isEmpty()) { @@ -657,6 +661,9 @@ static void run_test(skiatest::Test* test) { if (!FLAGS_dryRun) { start("unit", "test", "", test->name); GrContextFactory factory; + if (FLAGS_pre_log) { + SkDebugf("\nRunning test %s", test->name); + } test->proc(&reporter, &factory); } timer.end(); |