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

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

Issue 4983004: Fix more ChromeFrame tests so that they work on IE9. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Created 10 years, 1 month 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
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 <string> 5 #include <string>
6 6
7 #include "base/scoped_comptr_win.h" 7 #include "base/scoped_comptr_win.h"
8 #include "base/test/test_file_util.h" 8 #include "base/test/test_file_util.h"
9 #include "base/win/windows_version.h" 9 #include "base/win/windows_version.h"
10 #include "chrome_frame/test/chrome_frame_test_utils.h" 10 #include "chrome_frame/test/chrome_frame_test_utils.h"
(...skipping 283 matching lines...) Expand 10 before | Expand all | Expand 10 after
294 EXPECT_CALL(ie_mock_, OnLoad(IN_IE, StrEq(GetSimplePageUrl()))) 294 EXPECT_CALL(ie_mock_, OnLoad(IN_IE, StrEq(GetSimplePageUrl())))
295 .Times(1) 295 .Times(1)
296 .WillOnce(CloseBrowserMock(&ie_mock_)); 296 .WillOnce(CloseBrowserMock(&ie_mock_));
297 } else { 297 } else {
298 // If the page is being loaded in chrome frame then we will see 298 // If the page is being loaded in chrome frame then we will see
299 // a security dialog. 299 // a security dialog.
300 const char* kAlertDlgCaption = "Security Alert"; 300 const char* kAlertDlgCaption = "Security Alert";
301 win_observer_mock.WatchWindow(kAlertDlgCaption, ""); 301 win_observer_mock.WatchWindow(kAlertDlgCaption, "");
302 302
303 EXPECT_CALL(ie_mock_, OnBeforeNavigate2(_, testing::Field(&VARIANT::bstrVal, 303 EXPECT_CALL(ie_mock_, OnBeforeNavigate2(_, testing::Field(&VARIANT::bstrVal,
304 testing::StrCaseEq(GetSimplePageUrl())), _, _, _, _, _)) 304 testing::HasSubstr(GetSimplePageUrl())), _, _, _, _, _))
305 .Times(1); 305 .Times(testing::AtMost(2));
306 306
307 EXPECT_CALL(ie_mock_, OnNavigateComplete2(_, 307 EXPECT_CALL(ie_mock_, OnNavigateComplete2(_,
308 testing::Field(&VARIANT::bstrVal, StrEq(GetSimplePageUrl())))) 308 testing::Field(&VARIANT::bstrVal, StrEq(GetSimplePageUrl()))))
309 .Times(testing::AtMost(1)); 309 .Times(testing::AtMost(1));
310 310
311 EXPECT_CALL(win_observer_mock, OnWindowOpen(_)) 311 EXPECT_CALL(win_observer_mock, OnWindowOpen(_))
312 .Times(1) 312 .Times(1)
313 .WillOnce(DoCloseWindow()); 313 .WillOnce(DoCloseWindow());
314 EXPECT_CALL(win_observer_mock, OnWindowClose(_)) 314 EXPECT_CALL(win_observer_mock, OnWindowClose(_))
315 .Times(1) 315 .Times(1)
(...skipping 633 matching lines...) Expand 10 before | Expand all | Expand 10 after
949 DelayRefresh(&ie_mock_, &loop_, 2000), 949 DelayRefresh(&ie_mock_, &loop_, 2000),
950 DelayCloseBrowserMock(&loop_, 4000, &ie_mock_))); 950 DelayCloseBrowserMock(&loop_, 4000, &ie_mock_)));
951 951
952 EXPECT_CALL(ie_mock_, OnLoad(in_cf, StrEq(src_url))) 952 EXPECT_CALL(ie_mock_, OnLoad(in_cf, StrEq(src_url)))
953 .Times(2); 953 .Times(2);
954 954
955 LaunchIEAndNavigate(src_url); 955 LaunchIEAndNavigate(src_url);
956 } 956 }
957 957
958 } // namespace chrome_frame_test 958 } // namespace chrome_frame_test
OLDNEW
« no previous file with comments | « chrome_frame/test/chrome_frame_ui_test_utils.cc ('k') | chrome_frame/test/test_with_web_server.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698