OLD | NEW |
1 // Copyright 2016 The Chromium Authors. All rights reserved. | 1 // Copyright 2016 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/browser/ui/test/test_browser_dialog.h" | 5 #include "chrome/browser/ui/test/test_browser_dialog.h" |
6 | 6 |
7 #include "base/command_line.h" | 7 #include "base/command_line.h" |
8 #include "base/message_loop/message_loop.h" | 8 #include "base/message_loop/message_loop.h" |
9 #include "base/test/gtest_util.h" | 9 #include "base/test/gtest_util.h" |
| 10 #include "base/threading/thread_task_runner_handle.h" |
10 #include "chrome/browser/platform_util.h" | 11 #include "chrome/browser/platform_util.h" |
11 #include "ui/base/material_design/material_design_controller.h" | 12 #include "ui/base/material_design/material_design_controller.h" |
12 #include "ui/base/test/material_design_controller_test_api.h" | 13 #include "ui/base/test/material_design_controller_test_api.h" |
13 #include "ui/base/test/user_interactive_test_case.h" | 14 #include "ui/base/test/user_interactive_test_case.h" |
14 #include "ui/base/ui_base_switches.h" | 15 #include "ui/base/ui_base_switches.h" |
15 #include "ui/views/widget/widget.h" | 16 #include "ui/views/widget/widget.h" |
16 #include "ui/views/widget/widget_observer.h" | 17 #include "ui/views/widget/widget_observer.h" |
17 | 18 |
18 namespace { | 19 namespace { |
19 | 20 |
(...skipping 81 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
101 ASSERT_EQ(1u, added.size()); | 102 ASSERT_EQ(1u, added.size()); |
102 | 103 |
103 const DialogAction action = base::CommandLine::ForCurrentProcess()->HasSwitch( | 104 const DialogAction action = base::CommandLine::ForCurrentProcess()->HasSwitch( |
104 internal::kInteractiveSwitch) | 105 internal::kInteractiveSwitch) |
105 ? DialogAction::INTERACTIVE | 106 ? DialogAction::INTERACTIVE |
106 : DialogAction::CLOSE_NOW; | 107 : DialogAction::CLOSE_NOW; |
107 | 108 |
108 WidgetCloser closer(added[0], action); | 109 WidgetCloser closer(added[0], action); |
109 ::test::RunTestInteractively(); | 110 ::test::RunTestInteractively(); |
110 } | 111 } |
OLD | NEW |