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/test/ui/ui_test.h" | 5 #include "chrome/test/ui/ui_test.h" |
6 | 6 |
7 #include "base/file_path.h" | 7 #include "base/file_path.h" |
8 #include "base/message_loop.h" | 8 #include "base/message_loop.h" |
| 9 #include "base/singleton.h" |
9 #include "chrome/browser/browser_thread.h" | 10 #include "chrome/browser/browser_thread.h" |
10 #include "chrome/browser/dom_ui/html_dialog_ui.h" | 11 #include "chrome/browser/dom_ui/html_dialog_ui.h" |
11 #include "chrome/browser/tab_contents/tab_contents.h" | 12 #include "chrome/browser/tab_contents/tab_contents.h" |
12 #include "chrome/browser/renderer_host/render_widget_host_view.h" | 13 #include "chrome/browser/renderer_host/render_widget_host_view.h" |
13 #include "chrome/browser/views/html_dialog_view.h" | 14 #include "chrome/browser/views/html_dialog_view.h" |
14 #include "chrome/common/url_constants.h" | 15 #include "chrome/common/url_constants.h" |
15 #include "chrome/test/in_process_browser_test.h" | 16 #include "chrome/test/in_process_browser_test.h" |
16 #include "chrome/test/ui_test_utils.h" | 17 #include "chrome/test/ui_test_utils.h" |
17 #include "testing/gtest/include/gtest/gtest.h" | 18 #include "testing/gtest/include/gtest/gtest.h" |
18 #include "testing/gmock/include/gmock/gmock.h" | 19 #include "testing/gmock/include/gmock/gmock.h" |
(...skipping 177 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
196 set_bounds.set_height(0); | 197 set_bounds.set_height(0); |
197 | 198 |
198 html_view->MoveContents(tab_contents, set_bounds); | 199 html_view->MoveContents(tab_contents, set_bounds); |
199 ui_test_utils::RunMessageLoop(); | 200 ui_test_utils::RunMessageLoop(); |
200 html_view->GetWidget()->GetBounds(&actual_bounds, false); | 201 html_view->GetWidget()->GetBounds(&actual_bounds, false); |
201 EXPECT_LT(0, actual_bounds.width()); | 202 EXPECT_LT(0, actual_bounds.width()); |
202 EXPECT_LT(0, actual_bounds.height()); | 203 EXPECT_LT(0, actual_bounds.height()); |
203 | 204 |
204 MessageLoopForUI::current()->RemoveObserver(WindowChangedObserver::Get()); | 205 MessageLoopForUI::current()->RemoveObserver(WindowChangedObserver::Get()); |
205 } | 206 } |
OLD | NEW |