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

Side by Side Diff: chrome_frame/test/ui_test.cc

Issue 3191022: [chrome frame] Send mouse button messages to select a menu item if the deskto... (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: '' Created 10 years, 4 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « chrome_frame/test/chrome_frame_ui_test_utils.cc ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2010 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include <mshtmcid.h> 5 #include <mshtmcid.h>
6 #include <string> 6 #include <string>
7 7
8 #include "base/scoped_variant_win.h" 8 #include "base/scoped_variant_win.h"
9 #include "base/test/test_file_util.h" 9 #include "base/test/test_file_util.h"
10 #include "chrome/common/url_constants.h" 10 #include "chrome/common/url_constants.h"
(...skipping 306 matching lines...) Expand 10 before | Expand all | Expand 10 after
317 LaunchIEAndNavigate(GetSimplePageUrl()); 317 LaunchIEAndNavigate(GetSimplePageUrl());
318 } 318 }
319 319
320 // Test fixture for tests related to the context menu UI. Since the context 320 // Test fixture for tests related to the context menu UI. Since the context
321 // menus for CF and IE are different, these tests are not parameterized. 321 // menus for CF and IE are different, these tests are not parameterized.
322 class ContextMenuTest : public MockIEEventSinkTest, public testing::Test { 322 class ContextMenuTest : public MockIEEventSinkTest, public testing::Test {
323 public: 323 public:
324 ContextMenuTest() {} 324 ContextMenuTest() {}
325 325
326 virtual void SetUp() { 326 virtual void SetUp() {
327 // These tests must run on an unlocked desktop in order to use MSAA to
328 // select menu items.
329 ASSERT_TRUE(IsDesktopUnlocked())
330 << "This test must run on an unlocked desktop";
331
332 // These are UI-related tests, so we do not care about the exact 327 // These are UI-related tests, so we do not care about the exact
333 // navigations that occur. 328 // navigations that occur.
334 ie_mock_.ExpectAnyNavigations(); 329 ie_mock_.ExpectAnyNavigations();
335 EXPECT_CALL(ie_mock_, OnLoad(_, _)).Times(testing::AnyNumber()); 330 EXPECT_CALL(ie_mock_, OnLoad(_, _)).Times(testing::AnyNumber());
336 EXPECT_CALL(acc_observer_, OnAccDocLoad(_)).Times(testing::AnyNumber()); 331 EXPECT_CALL(acc_observer_, OnAccDocLoad(_)).Times(testing::AnyNumber());
337 } 332 }
338 333
339 protected: 334 protected:
340 testing::NiceMock<MockAccessibilityEventObserver> acc_observer_; 335 testing::NiceMock<MockAccessibilityEventObserver> acc_observer_;
341 }; 336 };
(...skipping 237 matching lines...) Expand 10 before | Expand all | Expand 10 after
579 EXPECT_CALL(acc_observer_, OnMenuPopup(_)) 574 EXPECT_CALL(acc_observer_, OnMenuPopup(_))
580 .WillOnce(DoDefaultAction(AccObjectMatcher(L"Forward"))); 575 .WillOnce(DoDefaultAction(AccObjectMatcher(L"Forward")));
581 576
582 EXPECT_CALL(ie_mock_, OnLoad(IN_IE, StrEq(page2))) 577 EXPECT_CALL(ie_mock_, OnLoad(IN_IE, StrEq(page2)))
583 .WillOnce(CloseBrowserMock(&ie_mock_)); 578 .WillOnce(CloseBrowserMock(&ie_mock_));
584 579
585 LaunchIEAndNavigate(page1); 580 LaunchIEAndNavigate(page1);
586 } 581 }
587 582
588 } // namespace chrome_frame_test 583 } // namespace chrome_frame_test
OLDNEW
« no previous file with comments | « chrome_frame/test/chrome_frame_ui_test_utils.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698