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 "base/file_util.h" | 5 #include "base/file_util.h" |
6 #include "base/string_util.h" | 6 #include "base/string_util.h" |
7 #include "base/sys_info.h" | 7 #include "base/sys_info.h" |
8 #include "base/values.h" | 8 #include "base/values.h" |
9 #include "chrome/app/chrome_dll_resource.h" | 9 #include "chrome/app/chrome_dll_resource.h" |
10 #include "chrome/common/chrome_constants.h" | 10 #include "chrome/common/chrome_constants.h" |
(...skipping 72 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
83 const std::wstring test_title(L"Title Of Awesomeness"); | 83 const std::wstring test_title(L"Title Of Awesomeness"); |
84 EXPECT_EQ(WindowCaptionFromPageTitle(test_title), GetWindowTitle()); | 84 EXPECT_EQ(WindowCaptionFromPageTitle(test_title), GetWindowTitle()); |
85 EXPECT_EQ(test_title, GetActiveTabTitle()); | 85 EXPECT_EQ(test_title, GetActiveTabTitle()); |
86 } | 86 } |
87 | 87 |
88 // Create 34 tabs and verify that a lot of processes have been created. The | 88 // Create 34 tabs and verify that a lot of processes have been created. The |
89 // exact number of processes depends on the amount of memory. Previously we | 89 // exact number of processes depends on the amount of memory. Previously we |
90 // had a hard limit of 31 processes and this test is mainly directed at | 90 // had a hard limit of 31 processes and this test is mainly directed at |
91 // verifying that we don't crash when we pass this limit. | 91 // verifying that we don't crash when we pass this limit. |
92 // Disabling this test http://code.google.com/p/chromium/issues/detail?id=8119 | 92 // Disabling this test http://code.google.com/p/chromium/issues/detail?id=8119 |
93 TEST_F(BrowserTest, DISABLED_ThirtyFourTabs) { | 93 TEST_F(BrowserTest, ThirtyFourTabs) { |
kuchhal
2009/02/26 21:02:46
You can remove the comment above this line too.
| |
94 std::wstring test_file = test_data_directory_; | 94 std::wstring test_file = test_data_directory_; |
95 file_util::AppendToPath(&test_file, L"title2.html"); | 95 file_util::AppendToPath(&test_file, L"title2.html"); |
96 GURL url(net::FilePathToFileURL(test_file)); | 96 GURL url(net::FilePathToFileURL(test_file)); |
97 scoped_ptr<BrowserProxy> window(automation()->GetBrowserWindow(0)); | 97 scoped_ptr<BrowserProxy> window(automation()->GetBrowserWindow(0)); |
98 // There is one initial tab. | 98 // There is one initial tab. |
99 for (int ix = 0; ix != 33; ++ix) { | 99 for (int ix = 0; ix != 33; ++ix) { |
100 EXPECT_TRUE(window->AppendTab(url)); | 100 EXPECT_TRUE(window->AppendTab(url)); |
101 } | 101 } |
102 int tab_count = 0; | 102 int tab_count = 0; |
103 EXPECT_TRUE(window->GetTabCount(&tab_count)); | 103 EXPECT_TRUE(window->GetTabCount(&tab_count)); |
(...skipping 171 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
275 std::wstring title = GetActiveTabTitle(); | 275 std::wstring title = GetActiveTabTitle(); |
276 if (title == L"PASSED") { | 276 if (title == L"PASSED") { |
277 // Success, bail out. | 277 // Success, bail out. |
278 break; | 278 break; |
279 } | 279 } |
280 } | 280 } |
281 | 281 |
282 if (i == 10) | 282 if (i == 10) |
283 FAIL() << "failed to get error page title"; | 283 FAIL() << "failed to get error page title"; |
284 } | 284 } |
OLD | NEW |