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 "content/public/test/content_browser_test.h" | 5 #include "content/public/test/content_browser_test.h" |
6 | 6 |
7 #include "base/command_line.h" | 7 #include "base/command_line.h" |
8 #include "base/location.h" | 8 #include "base/location.h" |
9 #include "base/process/launch.h" | 9 #include "base/process/launch.h" |
10 #include "base/single_thread_task_runner.h" | 10 #include "base/single_thread_task_runner.h" |
11 #include "base/strings/utf_string_conversions.h" | 11 #include "base/strings/utf_string_conversions.h" |
12 #include "base/test/launcher/test_launcher.h" | 12 #include "base/test/launcher/test_launcher.h" |
13 #include "base/thread_task_runner_handle.h" | 13 #include "base/threading/thread_task_runner_handle.h" |
14 #include "build/build_config.h" | 14 #include "build/build_config.h" |
15 #include "content/public/browser/render_process_host.h" | 15 #include "content/public/browser/render_process_host.h" |
16 #include "content/public/browser/render_process_host_observer.h" | 16 #include "content/public/browser/render_process_host_observer.h" |
17 #include "content/public/browser/web_contents.h" | 17 #include "content/public/browser/web_contents.h" |
18 #include "content/public/common/content_switches.h" | 18 #include "content/public/common/content_switches.h" |
19 #include "content/public/test/browser_test_utils.h" | 19 #include "content/public/test/browser_test_utils.h" |
20 #include "content/public/test/content_browser_test_utils.h" | 20 #include "content/public/test/content_browser_test_utils.h" |
21 #include "content/public/test/test_launcher.h" | 21 #include "content/public/test/test_launcher.h" |
22 #include "content/public/test/test_utils.h" | 22 #include "content/public/test/test_utils.h" |
23 #include "content/shell/browser/shell.h" | 23 #include "content/shell/browser/shell.h" |
(...skipping 156 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
180 | 180 |
181 IN_PROC_BROWSER_TEST_F(ContentBrowserTest, NonNestableTask) { | 181 IN_PROC_BROWSER_TEST_F(ContentBrowserTest, NonNestableTask) { |
182 bool non_nested_task_ran = false; | 182 bool non_nested_task_ran = false; |
183 base::ThreadTaskRunnerHandle::Get()->PostNonNestableTask( | 183 base::ThreadTaskRunnerHandle::Get()->PostNonNestableTask( |
184 FROM_HERE, base::Bind(&CallbackChecker, &non_nested_task_ran)); | 184 FROM_HERE, base::Bind(&CallbackChecker, &non_nested_task_ran)); |
185 content::RunAllPendingInMessageLoop(); | 185 content::RunAllPendingInMessageLoop(); |
186 ASSERT_TRUE(non_nested_task_ran); | 186 ASSERT_TRUE(non_nested_task_ran); |
187 } | 187 } |
188 | 188 |
189 } // namespace content | 189 } // namespace content |
OLD | NEW |