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

Side by Side Diff: chrome/browser/session_history_uitest.cc

Issue 5967003: Refactor UITestBase/ProxyLauncher. (Closed) Base URL: http://git.chromium.org/git/chromium.git@trunk
Patch Set: Nits fixed; homepage_ moved to UITestBase; process_, process_id_ moved to ProxyLauncher. Created 9 years, 11 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
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 "base/string_util.h" 5 #include "base/string_util.h"
6 #include "chrome/common/url_constants.h" 6 #include "chrome/common/url_constants.h"
7 #include "chrome/test/automation/tab_proxy.h" 7 #include "chrome/test/automation/tab_proxy.h"
8 #include "chrome/test/automation/browser_proxy.h" 8 #include "chrome/test/automation/browser_proxy.h"
9 #include "chrome/test/ui/ui_test.h" 9 #include "chrome/test/ui/ui_test.h"
10 #include "grit/generated_resources.h" 10 #include "grit/generated_resources.h"
(...skipping 138 matching lines...) Expand 10 before | Expand all | Expand 10 after
149 #define MAYBE_FrameBackForward FLAKY_FrameBackForward 149 #define MAYBE_FrameBackForward FLAKY_FrameBackForward
150 #else 150 #else
151 #define MAYBE_FrameBackForward FrameBackForward 151 #define MAYBE_FrameBackForward FrameBackForward
152 #endif 152 #endif
153 153
154 // Test that back/forward works when navigating in subframes. 154 // Test that back/forward works when navigating in subframes.
155 TEST_F(SessionHistoryTest, MAYBE_FrameBackForward) { 155 TEST_F(SessionHistoryTest, MAYBE_FrameBackForward) {
156 ASSERT_TRUE(test_server_.Start()); 156 ASSERT_TRUE(test_server_.Start());
157 157
158 // about:blank should be loaded first. 158 // about:blank should be loaded first.
159 GURL home(homepage_); 159 GURL home(chrome::kAboutBlankURL);
John Grabowski 2011/01/07 03:36:11 You added a set_homepage() to replace "homepage_ =
dtu 2011/01/08 01:54:57 Done.
160 ASSERT_FALSE(tab_->GoBack()); 160 ASSERT_FALSE(tab_->GoBack());
161 EXPECT_EQ(L"", GetTabTitle()); 161 EXPECT_EQ(L"", GetTabTitle());
162 EXPECT_EQ(home, GetTabURL()); 162 EXPECT_EQ(home, GetTabURL());
163 163
164 GURL frames(test_server_.GetURL("files/session_history/frames.html")); 164 GURL frames(test_server_.GetURL("files/session_history/frames.html"));
165 ASSERT_TRUE(tab_->NavigateToURL(frames)); 165 ASSERT_TRUE(tab_->NavigateToURL(frames));
166 EXPECT_EQ(L"bot1", GetTabTitle()); 166 EXPECT_EQ(L"bot1", GetTabTitle());
167 EXPECT_EQ(frames, GetTabURL()); 167 EXPECT_EQ(frames, GetTabURL());
168 168
169 ClickLink("abot2"); 169 ClickLink("abot2");
(...skipping 394 matching lines...) Expand 10 before | Expand all | Expand 10 after
564 ASSERT_TRUE(tab_->GoBack()); 564 ASSERT_TRUE(tab_->GoBack());
565 565
566 // Ensure history.length is properly truncated. 566 // Ensure history.length is properly truncated.
567 ASSERT_TRUE(tab_->NavigateToURL(test_server_.GetURL("files/title2.html"))); 567 ASSERT_TRUE(tab_->NavigateToURL(test_server_.GetURL("files/title2.html")));
568 ASSERT_TRUE(tab_->ExecuteAndExtractInt( 568 ASSERT_TRUE(tab_->ExecuteAndExtractInt(
569 L"", L"domAutomationController.send(history.length)", &length)); 569 L"", L"domAutomationController.send(history.length)", &length));
570 EXPECT_EQ(2, length); 570 EXPECT_EQ(2, length);
571 } 571 }
572 572
573 } // namespace 573 } // namespace
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698