OLD | NEW |
---|---|
1 // Copyright (c) 2006-2008 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2006-2008 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 "app/l10n_util.h" | 5 #include "app/l10n_util.h" |
6 #include "base/file_path.h" | 6 #include "base/file_path.h" |
7 #include "base/platform_thread.h" | 7 #include "base/platform_thread.h" |
8 #include "base/string_util.h" | 8 #include "base/string_util.h" |
9 #include "chrome/common/url_constants.h" | 9 #include "chrome/common/url_constants.h" |
10 #include "chrome/test/automation/tab_proxy.h" | 10 #include "chrome/test/automation/tab_proxy.h" |
(...skipping 474 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
485 | 485 |
486 // This test is flaky. It looks like the server does not start fast enough, | 486 // This test is flaky. It looks like the server does not start fast enough, |
487 // and the navigation fails (with 404). See http://crbug.com/8444. | 487 // and the navigation fails (with 404). See http://crbug.com/8444. |
488 TEST_F(SessionHistoryTest, FLAKY_LocationReplace) { | 488 TEST_F(SessionHistoryTest, FLAKY_LocationReplace) { |
489 // Test that using location.replace doesn't leave the title of the old page | 489 // Test that using location.replace doesn't leave the title of the old page |
490 // visible. | 490 // visible. |
491 scoped_refptr<HTTPTestServer> server = | 491 scoped_refptr<HTTPTestServer> server = |
492 HTTPTestServer::CreateServer(kDocRoot, NULL); | 492 HTTPTestServer::CreateServer(kDocRoot, NULL); |
493 ASSERT_TRUE(NULL != server.get()); | 493 ASSERT_TRUE(NULL != server.get()); |
494 | 494 |
495 ASSERT_TRUE(tab_->NavigateToURL(server->TestServerPage( | 495 ASSERT_TRUE(tab_->NavigateToURLBlockUntilNavigationsComplete( |
Mike Belshe
2009/11/26 17:03:12
Is this an accidental file inclusion to this CL?
| |
496 "files/session_history/replace.html?no-title.html"))); | 496 server->TestServerPage( |
497 "files/session_history/replace.html?no-title.html"), 2)); | |
497 EXPECT_EQ(L"", GetTabTitle()); | 498 EXPECT_EQ(L"", GetTabTitle()); |
498 } | 499 } |
499 | 500 |
500 // This test is flaky. See bug 22111. | 501 // This test is flaky. See bug 22111. |
501 TEST_F(SessionHistoryTest, FLAKY_HistorySearchXSS) { | 502 TEST_F(SessionHistoryTest, FLAKY_HistorySearchXSS) { |
502 // about:blank should be loaded first. | 503 // about:blank should be loaded first. |
503 ASSERT_FALSE(tab_->GoBack()); | 504 ASSERT_FALSE(tab_->GoBack()); |
504 EXPECT_EQ(L"", GetTabTitle()); | 505 EXPECT_EQ(L"", GetTabTitle()); |
505 | 506 |
506 GURL url(std::string(chrome::kChromeUIHistoryURL) + | 507 GURL url(std::string(chrome::kChromeUIHistoryURL) + |
(...skipping 18 matching lines...) Expand all Loading... | |
525 | 526 |
526 ASSERT_TRUE(tab_->NavigateToURL(GURL( | 527 ASSERT_TRUE(tab_->NavigateToURL(GURL( |
527 "javascript:void(frames[0].navigate())"))); | 528 "javascript:void(frames[0].navigate())"))); |
528 EXPECT_EQ(L"foo", GetTabTitle()); | 529 EXPECT_EQ(L"foo", GetTabTitle()); |
529 | 530 |
530 ASSERT_TRUE(tab_->GoBack()); | 531 ASSERT_TRUE(tab_->GoBack()); |
531 EXPECT_EQ(L"Default Title", GetTabTitle()); | 532 EXPECT_EQ(L"Default Title", GetTabTitle()); |
532 } | 533 } |
533 | 534 |
534 } // namespace | 535 } // namespace |
OLD | NEW |