diff options
author | robertshield@chromium.org <robertshield@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2013-01-21 18:46:05 +0000 |
---|---|---|
committer | robertshield@chromium.org <robertshield@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2013-01-21 18:46:05 +0000 |
commit | 1c3f7002d91087f655dc805ac115e69ce1dc02fb (patch) | |
tree | 5ab0a121c2901bbcd16731c8236b6db527024833 /ash/tooltips | |
parent | 345f3919f5b66370ddc2152468286b381ffb5bbb (diff) | |
download | chromium_src-1c3f7002d91087f655dc805ac115e69ce1dc02fb.zip chromium_src-1c3f7002d91087f655dc805ac115e69ce1dc02fb.tar.gz chromium_src-1c3f7002d91087f655dc805ac115e69ce1dc02fb.tar.bz2 |
Initial whack at getting ash_unittests to connect to a viewer process on Win/Metro.
This adds a test viewer process host to the ash unittests that starts and connects to the viewer process, using the provided hwnd as a backing surface for the tests.
This approach allows most of the ash unittests to pass except for two categories:
1) Tests that spin up more than one ash display. These don't work since each RootWindowHost thus created would require a remote connection and there is only one Metro viewer process.
2) Some number of tests seem to tickle a crash in shader.cc. These are short-circuited on Win8 with a TODO.
Some limitations:
1) The tests require chrome.exe to be registered as the default browser on Windows 8 to be used as a viewer process. This could be fixed in a future CL by creating a minimal viewer process for tests.
2) To register chrome.exe as the default browser, setup.exe needs to be built and run with
setup.exe --register-dev-chrome --register-dev-chrome-suffix=.test
This will be fixed in a future CL by extracting the registration code.
The interesting parts are in ash/test/test_metro_viewer_process_host.h
ash/test/test_metro_viewer_process_host.cc
Most of the rest is test disabling or calling the above.
BUG=154081
TEST=ash_unittests.exe on win8.
Review URL: https://chromiumcodereview.appspot.com/11830038
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@177946 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'ash/tooltips')
-rw-r--r-- | ash/tooltips/tooltip_controller_unittest.cc | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/ash/tooltips/tooltip_controller_unittest.cc b/ash/tooltips/tooltip_controller_unittest.cc index 4426654..f05c15b 100644 --- a/ash/tooltips/tooltip_controller_unittest.cc +++ b/ash/tooltips/tooltip_controller_unittest.cc @@ -479,7 +479,16 @@ TEST_F(TooltipControllerTest, TooltipHidesOnTimeoutAndStaysHiddenUntilChange) { EXPECT_EQ(window, GetTooltipWindow()); } -TEST_F(TooltipControllerTest, TooltipsOnMultiDisplayShouldNotCrash) { +#if defined(OS_WIN) +// Multiple displays are not supported on Windows Ash. http://crbug.com/165962 +#define MAYBE_TooltipsOnMultiDisplayShouldNotCrash \ + DISABLED_TooltipsOnMultiDisplayShouldNotCrash +#else +#define MAYBE_TooltipsOnMultiDisplayShouldNotCrash \ + TooltipsOnMultiDisplayShouldNotCrash +#endif + +TEST_F(TooltipControllerTest, MAYBE_TooltipsOnMultiDisplayShouldNotCrash) { UpdateDisplay("1000x600,600x400"); Shell::RootWindowList root_windows = Shell::GetAllRootWindows(); scoped_ptr<views::Widget> widget1(CreateNewWidgetWithBoundsOn( |