summaryrefslogtreecommitdiffstats
path: root/chromeos
diff options
context:
space:
mode:
authorelizavetai@chromium.org <elizavetai@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2014-07-31 20:10:10 +0000
committerelizavetai@chromium.org <elizavetai@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2014-07-31 20:10:10 +0000
commitd94ea9a9b483532d4f48ebd75757352155c4ab92 (patch)
tree1ba414c1e34412f326745e7543b2cf2521ef7117 /chromeos
parent300fc335ab94e68bb69fa31fa9fb5608dba6db26 (diff)
downloadchromium_src-d94ea9a9b483532d4f48ebd75757352155c4ab92.zip
chromium_src-d94ea9a9b483532d4f48ebd75757352155c4ab92.tar.gz
chromium_src-d94ea9a9b483532d4f48ebd75757352155c4ab92.tar.bz2
Continues https://codereview.chromium.org/405093003, so general description is there.
Now the testing mode has appeared: ScreenshotTester can now load the golden screenshot from the disk and compare it to the screenshot taken right now. It still should be turned on with switches. To turn testing with screenshots on, --enable-screenshot-testing-with-mode=MODE is used, where MODE can be "test" or "update". "update" updates golden screenshot and requires --golden-screenshots-dir=DIR: place to store golden screenshots. "test" runs comparing golden screenshot with current one, and --artifacts-dir=DIR can be used, where DIR is the place to store screenshots that are different from golden ones if they exist, and also an image representing difference between screenshots. If no --artifacts-dir switch is found, these bugproofs are saved to the directory with golden screenshots. BUG=395653 Review URL: https://codereview.chromium.org/433873002 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@286880 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chromeos')
-rw-r--r--chromeos/chromeos_switches.cc18
-rw-r--r--chromeos/chromeos_switches.h5
2 files changed, 14 insertions, 9 deletions
diff --git a/chromeos/chromeos_switches.cc b/chromeos/chromeos_switches.cc
index d027ef0..471c250 100644
--- a/chromeos/chromeos_switches.cc
+++ b/chromeos/chromeos_switches.cc
@@ -96,13 +96,14 @@ const char kEnableNetworkPortalNotification[] =
// Enables activation of voice search by saying 'Ok Google'.
const char kEnableOkGoogleVoiceSearch[] = "enable-ok-google-voice-search";
-// Enables using screenshots in tests.
-const char kEnableScreenshotTesting[] = "enable-screenshot-testing";
-
// Enables touchpad three-finger-click as middle button.
const char kEnableTouchpadThreeFingerClick[]
= "enable-touchpad-three-finger-click";
+// Enables using screenshots in tests and seets mode.
+const char kEnableScreenshotTestingWithMode[] =
+ "enable-screenshot-testing-with-mode";
+
// Enable Kiosk mode for ChromeOS. Note this switch refers to retail mode rather
// than the kiosk app mode.
const char kEnableKioskMode[] = "enable-kiosk-mode";
@@ -240,12 +241,15 @@ const char kEnableFirstRunUITransitions[] = "enable-first-run-ui-transitions";
// Forces first-run UI to be shown for every login.
const char kForceFirstRunUI[] = "force-first-run-ui";
-// Turns on screenshot testing and specifies the directory where the
-// golden screenshots are stored.
-const char kScreenshotDestinationDir[] = "screenshot-destination-dir";
-
// Enables testing for auto update UI.
const char kTestAutoUpdateUI[] = "test-auto-update-ui";
+// Screenshot testing: specifies the directory where the golden screenshots are
+// stored.
+const char kGoldenScreenshotsDir[] = "golden-screenshots-dir";
+
+// Screenshot testing: specifies the directoru where artifacts will be stored.
+const char kArtifactsDir[] = "artifacts-dir";
+
} // namespace switches
} // namespace chromeos
diff --git a/chromeos/chromeos_switches.h b/chromeos/chromeos_switches.h
index b7bc3b3..1c3a9ed 100644
--- a/chromeos/chromeos_switches.h
+++ b/chromeos/chromeos_switches.h
@@ -80,8 +80,9 @@ CHROMEOS_EXPORT extern const char kShowHostPairingDemo[];
CHROMEOS_EXPORT extern const char kSmsTestMessages[];
CHROMEOS_EXPORT extern const char kStubCrosSettings[];
CHROMEOS_EXPORT extern const char kTestAutoUpdateUI[];
-CHROMEOS_EXPORT extern const char kEnableScreenshotTesting[];
-CHROMEOS_EXPORT extern const char kScreenshotDestinationDir[];
+CHROMEOS_EXPORT extern const char kEnableScreenshotTestingWithMode[];
+CHROMEOS_EXPORT extern const char kGoldenScreenshotsDir[];
+CHROMEOS_EXPORT extern const char kArtifactsDir[];
} // namespace switches
} // namespace chromeos