| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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/bind_helpers.h" | 6 #include "base/bind_helpers.h" |
| 7 #include "base/location.h" | 7 #include "base/location.h" |
| 8 #include "base/macros.h" |
| 8 #include "base/message_loop/message_loop.h" | 9 #include "base/message_loop/message_loop.h" |
| 10 #include "build/build_config.h" |
| 9 #include "chrome/browser/profiles/profile.h" | 11 #include "chrome/browser/profiles/profile.h" |
| 10 #include "chrome/browser/ui/browser.h" | 12 #include "chrome/browser/ui/browser.h" |
| 11 #include "chrome/browser/ui/browser_window.h" | 13 #include "chrome/browser/ui/browser_window.h" |
| 12 #include "chrome/browser/ui/tabs/tab_strip_model.h" | 14 #include "chrome/browser/ui/tabs/tab_strip_model.h" |
| 13 #include "chrome/browser/ui/webui/chrome_web_contents_handler.h" | 15 #include "chrome/browser/ui/webui/chrome_web_contents_handler.h" |
| 14 #include "chrome/common/url_constants.h" | 16 #include "chrome/common/url_constants.h" |
| 15 #include "chrome/test/base/in_process_browser_test.h" | 17 #include "chrome/test/base/in_process_browser_test.h" |
| 16 #include "chrome/test/base/ui_test_utils.h" | 18 #include "chrome/test/base/ui_test_utils.h" |
| 17 #include "content/public/browser/browser_context.h" | 19 #include "content/public/browser/browser_context.h" |
| 18 #include "content/public/browser/render_widget_host_view.h" | 20 #include "content/public/browser/render_widget_host_view.h" |
| (...skipping 208 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 227 view_->GetWidget()->widget_delegate()->GetModalType()); | 229 view_->GetWidget()->widget_delegate()->GetModalType()); |
| 228 | 230 |
| 229 // Close the parent window. Tear down may happen asynchronously. | 231 // Close the parent window. Tear down may happen asynchronously. |
| 230 EXPECT_FALSE(web_dialog_delegate_destroyed_); | 232 EXPECT_FALSE(web_dialog_delegate_destroyed_); |
| 231 EXPECT_FALSE(web_dialog_view_destroyed_); | 233 EXPECT_FALSE(web_dialog_view_destroyed_); |
| 232 browser()->window()->Close(); | 234 browser()->window()->Close(); |
| 233 content::RunAllPendingInMessageLoop(); | 235 content::RunAllPendingInMessageLoop(); |
| 234 EXPECT_TRUE(web_dialog_delegate_destroyed_); | 236 EXPECT_TRUE(web_dialog_delegate_destroyed_); |
| 235 EXPECT_TRUE(web_dialog_view_destroyed_); | 237 EXPECT_TRUE(web_dialog_view_destroyed_); |
| 236 } | 238 } |
| OLD | NEW |