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 "chrome/browser/extensions/api/messaging/native_message_process_host.h" | 5 #include "chrome/browser/extensions/api/messaging/native_message_process_host.h" |
6 | 6 |
7 #include <stddef.h> | 7 #include <stddef.h> |
8 #include <stdint.h> | 8 #include <stdint.h> |
9 | 9 |
10 #include <memory> | 10 #include <memory> |
(...skipping 10 matching lines...) Expand all Loading... |
21 #include "base/rand_util.h" | 21 #include "base/rand_util.h" |
22 #include "base/run_loop.h" | 22 #include "base/run_loop.h" |
23 #include "base/strings/stringprintf.h" | 23 #include "base/strings/stringprintf.h" |
24 #include "base/test/test_timeouts.h" | 24 #include "base/test/test_timeouts.h" |
25 #include "base/threading/platform_thread.h" | 25 #include "base/threading/platform_thread.h" |
26 #include "base/threading/sequenced_worker_pool.h" | 26 #include "base/threading/sequenced_worker_pool.h" |
27 #include "base/time/time.h" | 27 #include "base/time/time.h" |
28 #include "build/build_config.h" | 28 #include "build/build_config.h" |
29 #include "chrome/browser/extensions/api/messaging/native_messaging_test_util.h" | 29 #include "chrome/browser/extensions/api/messaging/native_messaging_test_util.h" |
30 #include "chrome/browser/extensions/api/messaging/native_process_launcher.h" | 30 #include "chrome/browser/extensions/api/messaging/native_process_launcher.h" |
31 #include "chrome/common/extensions/features/feature_channel.h" | |
32 #include "components/version_info/version_info.h" | 31 #include "components/version_info/version_info.h" |
33 #include "content/public/browser/browser_thread.h" | 32 #include "content/public/browser/browser_thread.h" |
34 #include "content/public/test/test_browser_thread_bundle.h" | 33 #include "content/public/test/test_browser_thread_bundle.h" |
35 #include "extensions/common/extension.h" | 34 #include "extensions/common/extension.h" |
| 35 #include "extensions/common/features/feature_channel.h" |
36 #include "testing/gtest/include/gtest/gtest.h" | 36 #include "testing/gtest/include/gtest/gtest.h" |
37 | 37 |
38 #if defined(OS_WIN) | 38 #if defined(OS_WIN) |
39 #include <windows.h> | 39 #include <windows.h> |
40 #include "base/win/scoped_handle.h" | 40 #include "base/win/scoped_handle.h" |
41 #else | 41 #else |
42 #include <unistd.h> | 42 #include <unistd.h> |
43 #endif | 43 #endif |
44 | 44 |
45 using content::BrowserThread; | 45 using content::BrowserThread; |
(...skipping 280 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
326 native_message_host_->Start(this); | 326 native_message_host_->Start(this); |
327 ASSERT_TRUE(native_message_host_.get()); | 327 ASSERT_TRUE(native_message_host_.get()); |
328 run_loop_.reset(new base::RunLoop()); | 328 run_loop_.reset(new base::RunLoop()); |
329 run_loop_->Run(); | 329 run_loop_->Run(); |
330 | 330 |
331 // The host should fail to start. | 331 // The host should fail to start. |
332 ASSERT_TRUE(channel_closed_); | 332 ASSERT_TRUE(channel_closed_); |
333 } | 333 } |
334 | 334 |
335 } // namespace extensions | 335 } // namespace extensions |
OLD | NEW |