| OLD | NEW |
| 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 "chrome/app/chrome_command_ids.h" | 5 #include "chrome/app/chrome_command_ids.h" |
| 6 #include "chrome/common/url_constants.h" | 6 #include "chrome/common/url_constants.h" |
| 7 #include "chrome/test/automation/browser_proxy.h" | 7 #include "chrome/test/automation/browser_proxy.h" |
| 8 #include "chrome/test/automation/tab_proxy.h" | 8 #include "chrome/test/automation/tab_proxy.h" |
| 9 #include "chrome/test/ui/ui_test.h" | 9 #include "chrome/test/ui/ui_test.h" |
| 10 #include "net/test/test_server.h" | 10 #include "net/test/test_server.h" |
| (...skipping 73 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 84 ASSERT_TRUE(test_server_.Start()); | 84 ASSERT_TRUE(test_server_.Start()); |
| 85 | 85 |
| 86 GURL url(test_server_.GetURL(kTestHtml)); | 86 GURL url(test_server_.GetURL(kTestHtml)); |
| 87 NavigateToURL(url); | 87 NavigateToURL(url); |
| 88 | 88 |
| 89 EXPECT_TRUE(IsMenuCommandEnabled(IDC_VIEW_SOURCE)); | 89 EXPECT_TRUE(IsMenuCommandEnabled(IDC_VIEW_SOURCE)); |
| 90 } | 90 } |
| 91 | 91 |
| 92 // Make sure that when looking at the page source, we can't select "View Source" | 92 // Make sure that when looking at the page source, we can't select "View Source" |
| 93 // from the menu. | 93 // from the menu. |
| 94 TEST_F(ViewSourceTest, ViewSourceInMenuDisabledWhileViewingSource) { | 94 // |
| 95 // Occasionally crashes on all platforms, see http://crbug.com/69249 |
| 96 TEST_F(ViewSourceTest, FLAKY_ViewSourceInMenuDisabledWhileViewingSource) { |
| 95 ASSERT_TRUE(test_server_.Start()); | 97 ASSERT_TRUE(test_server_.Start()); |
| 96 | 98 |
| 97 GURL url_viewsource(chrome::kViewSourceScheme + std::string(":") + | 99 GURL url_viewsource(chrome::kViewSourceScheme + std::string(":") + |
| 98 test_server_.GetURL(kTestHtml).spec()); | 100 test_server_.GetURL(kTestHtml).spec()); |
| 99 NavigateToURL(url_viewsource); | 101 NavigateToURL(url_viewsource); |
| 100 | 102 |
| 101 EXPECT_FALSE(IsMenuCommandEnabled(IDC_VIEW_SOURCE)); | 103 EXPECT_FALSE(IsMenuCommandEnabled(IDC_VIEW_SOURCE)); |
| 102 } | 104 } |
| 103 | 105 |
| 104 } // namespace | 106 } // namespace |
| OLD | NEW |