| OLD | NEW |
| 1 // Copyright (c) 2006-2009 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2006-2009 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 // This file provides reliablity test which runs under UI test framework. The | 5 // This file provides reliablity test which runs under UI test framework. The |
| 6 // test is intended to run within QEMU environment. | 6 // test is intended to run within QEMU environment. |
| 7 // | 7 // |
| 8 // Usage 1: reliability_test | 8 // Usage 1: reliability_test |
| 9 // Upon invocation, it visits a hard coded list of sample URLs. This is mainly | 9 // Upon invocation, it visits a hard coded list of sample URLs. This is mainly |
| 10 // used by buildbot, to verify reliability_test itself runs ok. | 10 // used by buildbot, to verify reliability_test itself runs ok. |
| (...skipping 175 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 186 test_log << (time_now.ToDoubleT() - time_start) << std::endl; | 186 test_log << (time_now.ToDoubleT() - time_start) << std::endl; |
| 187 | 187 |
| 188 bool is_timeout = false; | 188 bool is_timeout = false; |
| 189 int result = AUTOMATION_MSG_NAVIGATION_ERROR; | 189 int result = AUTOMATION_MSG_NAVIGATION_ERROR; |
| 190 // This is essentially what NavigateToURL does except we don't fire | 190 // This is essentially what NavigateToURL does except we don't fire |
| 191 // assertion when page loading fails. We log the result instead. | 191 // assertion when page loading fails. We log the result instead. |
| 192 { | 192 { |
| 193 // TabProxy should be released before Browser is closed. | 193 // TabProxy should be released before Browser is closed. |
| 194 scoped_refptr<TabProxy> tab_proxy(GetActiveTab()); | 194 scoped_refptr<TabProxy> tab_proxy(GetActiveTab()); |
| 195 if (tab_proxy.get()) { | 195 if (tab_proxy.get()) { |
| 196 result = tab_proxy->NavigateToURLWithTimeout(url, g_timeout_ms, | 196 result = tab_proxy->NavigateToURLWithTimeout(url, 1, g_timeout_ms, |
| 197 &is_timeout); | 197 &is_timeout); |
| 198 } | 198 } |
| 199 | 199 |
| 200 if (!is_timeout && result == AUTOMATION_MSG_NAVIGATION_SUCCESS) { | 200 if (!is_timeout && result == AUTOMATION_MSG_NAVIGATION_SUCCESS) { |
| 201 if (g_page_down) { | 201 if (g_page_down) { |
| 202 // Page down twice. | 202 // Page down twice. |
| 203 scoped_refptr<BrowserProxy> browser( | 203 scoped_refptr<BrowserProxy> browser( |
| 204 automation()->GetBrowserWindow(0)); | 204 automation()->GetBrowserWindow(0)); |
| 205 if (browser.get()) { | 205 if (browser.get()) { |
| 206 scoped_refptr<WindowProxy> window(browser->GetWindow()); | 206 scoped_refptr<WindowProxy> window(browser->GetWindow()); |
| (...skipping 550 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 757 g_v8_log_path = FilePath::FromWStringHack( | 757 g_v8_log_path = FilePath::FromWStringHack( |
| 758 v8_command_line.GetSwitchValue(kV8LogFileSwitch)); | 758 v8_command_line.GetSwitchValue(kV8LogFileSwitch)); |
| 759 if (!file_util::AbsolutePath(&g_v8_log_path)) { | 759 if (!file_util::AbsolutePath(&g_v8_log_path)) { |
| 760 g_v8_log_path = FilePath(); | 760 g_v8_log_path = FilePath(); |
| 761 } | 761 } |
| 762 } | 762 } |
| 763 } | 763 } |
| 764 } | 764 } |
| 765 } | 765 } |
| 766 } | 766 } |
| OLD | NEW |