Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1593)

Unified Diff: chrome/browser/plugins/plugin_power_saver_browsertest.cc

Issue 1856043002: Plugin Power Saver: Rebaseline pixel tests. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | chrome/test/data/plugin_power_saver/large_cross_origin_obscured_expected.png » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/plugins/plugin_power_saver_browsertest.cc
diff --git a/chrome/browser/plugins/plugin_power_saver_browsertest.cc b/chrome/browser/plugins/plugin_power_saver_browsertest.cc
index 00bd0bcf0c9e45fbd243fbbc540a14ec9f03fd3e..7353640ad01f9ce8846f5cd371808001d47f8b54 100644
--- a/chrome/browser/plugins/plugin_power_saver_browsertest.cc
+++ b/chrome/browser/plugins/plugin_power_saver_browsertest.cc
@@ -230,11 +230,9 @@ void CompareSnapshotToReference(const base::FilePath& reference,
*snapshot_matches = SnapshotMatches(reference, bitmap);
- // When rebaselining the pixel test, the test will fail, and we will
- // overwrite the reference file. On the next try through, the test will then
- // pass, since we just overwrote the reference file. A bit wonky.
- if (!(*snapshot_matches) &&
- base::CommandLine::ForCurrentProcess()->HasSwitch(
+ // When rebaselining the pixel test, the test may fail. However, the
+ // reference file will still be overwritten.
+ if (base::CommandLine::ForCurrentProcess()->HasSwitch(
switches::kRebaselinePixelTests)) {
SkBitmap clipped_bitmap;
bitmap.extractSubset(&clipped_bitmap,
« no previous file with comments | « no previous file | chrome/test/data/plugin_power_saver/large_cross_origin_obscured_expected.png » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698