| OLD | NEW |
| 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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/bind.h" | 5 #include "base/bind.h" |
| 6 #include "base/cancelable_callback.h" | 6 #include "base/cancelable_callback.h" |
| 7 #include "base/command_line.h" | 7 #include "base/command_line.h" |
| 8 #include "base/memory/ref_counted.h" | 8 #include "base/memory/ref_counted.h" |
| 9 #include "base/path_service.h" | 9 #include "base/path_service.h" |
| 10 #include "base/stringprintf.h" | 10 #include "base/stringprintf.h" |
| (...skipping 484 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 495 #endif | 495 #endif |
| 496 // Tests that inspector will reattach to inspected page when it is reloaded | 496 // Tests that inspector will reattach to inspected page when it is reloaded |
| 497 // after a crash. See http://crbug.com/101952 | 497 // after a crash. See http://crbug.com/101952 |
| 498 IN_PROC_BROWSER_TEST_F(DevToolsSanityTest, TestReattachAfterCrash) { | 498 IN_PROC_BROWSER_TEST_F(DevToolsSanityTest, TestReattachAfterCrash) { |
| 499 OpenDevToolsWindow(kDebuggerTestPage); | 499 OpenDevToolsWindow(kDebuggerTestPage); |
| 500 | 500 |
| 501 ui_test_utils::CrashTab(GetInspectedTab()); | 501 ui_test_utils::CrashTab(GetInspectedTab()); |
| 502 ui_test_utils::WindowedNotificationObserver observer( | 502 ui_test_utils::WindowedNotificationObserver observer( |
| 503 content::NOTIFICATION_LOAD_STOP, | 503 content::NOTIFICATION_LOAD_STOP, |
| 504 content::Source<NavigationController>( | 504 content::Source<NavigationController>( |
| 505 &browser()->GetSelectedTabContentsWrapper()->controller())); | 505 &browser()->GetSelectedTabContentsWrapper()->tab_contents()-> |
| 506 controller())); |
| 506 browser()->Reload(CURRENT_TAB); | 507 browser()->Reload(CURRENT_TAB); |
| 507 observer.Wait(); | 508 observer.Wait(); |
| 508 | 509 |
| 509 RunTestFuntion(window_, "testReattachAfterCrash"); | 510 RunTestFuntion(window_, "testReattachAfterCrash"); |
| 510 CloseDevToolsWindow(); | 511 CloseDevToolsWindow(); |
| 511 } | 512 } |
| 512 | 513 |
| 513 IN_PROC_BROWSER_TEST_F(DevToolsSanityTest, TestPageWithNoJavaScript) { | 514 IN_PROC_BROWSER_TEST_F(DevToolsSanityTest, TestPageWithNoJavaScript) { |
| 514 OpenDevToolsWindow("about:blank"); | 515 OpenDevToolsWindow("about:blank"); |
| 515 std::string result; | 516 std::string result; |
| (...skipping 44 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 560 | 561 |
| 561 // Reload page to restart the worker. | 562 // Reload page to restart the worker. |
| 562 ui_test_utils::NavigateToURL(browser(), url); | 563 ui_test_utils::NavigateToURL(browser(), url); |
| 563 | 564 |
| 564 // Wait until worker script is paused on the debugger statement. | 565 // Wait until worker script is paused on the debugger statement. |
| 565 RunTestFuntion(window_, "testPauseInSharedWorkerInitialization"); | 566 RunTestFuntion(window_, "testPauseInSharedWorkerInitialization"); |
| 566 CloseDevToolsWindow(); | 567 CloseDevToolsWindow(); |
| 567 } | 568 } |
| 568 | 569 |
| 569 } // namespace | 570 } // namespace |
| OLD | NEW |