| OLD | NEW |
| 1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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 <stddef.h> | 5 #include <stddef.h> |
| 6 #include <stdint.h> | 6 #include <stdint.h> |
| 7 | 7 |
| 8 #include <algorithm> | 8 #include <algorithm> |
| 9 #include <utility> | 9 #include <utility> |
| 10 | 10 |
| 11 #include "base/containers/scoped_ptr_hash_map.h" | 11 #include "base/containers/scoped_ptr_hash_map.h" |
| 12 #include "base/location.h" | 12 #include "base/location.h" |
| 13 #include "base/memory/ptr_util.h" | 13 #include "base/memory/ptr_util.h" |
| 14 #include "base/single_thread_task_runner.h" | 14 #include "base/single_thread_task_runner.h" |
| 15 #include "base/strings/utf_string_conversions.h" | 15 #include "base/strings/utf_string_conversions.h" |
| 16 #include "base/thread_task_runner_handle.h" | 16 #include "base/threading/thread_task_runner_handle.h" |
| 17 #include "chrome/browser/devtools/device/adb/mock_adb_server.h" | 17 #include "chrome/browser/devtools/device/adb/mock_adb_server.h" |
| 18 #include "chrome/browser/devtools/device/devtools_android_bridge.h" | 18 #include "chrome/browser/devtools/device/devtools_android_bridge.h" |
| 19 #include "chrome/browser/devtools/device/usb/android_usb_device.h" | 19 #include "chrome/browser/devtools/device/usb/android_usb_device.h" |
| 20 #include "chrome/browser/devtools/device/usb/usb_device_provider.h" | 20 #include "chrome/browser/devtools/device/usb/usb_device_provider.h" |
| 21 #include "chrome/browser/ui/browser.h" | 21 #include "chrome/browser/ui/browser.h" |
| 22 #include "chrome/test/base/in_process_browser_test.h" | 22 #include "chrome/test/base/in_process_browser_test.h" |
| 23 #include "content/public/browser/browser_thread.h" | 23 #include "content/public/browser/browser_thread.h" |
| 24 #include "content/public/test/test_utils.h" | 24 #include "content/public/test/test_utils.h" |
| 25 #include "device/core/device_client.h" | 25 #include "device/core/device_client.h" |
| 26 #include "device/usb/usb_descriptors.h" | 26 #include "device/usb/usb_descriptors.h" |
| (...skipping 771 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 798 EXPECT_EQ(2, listener.invoked_); | 798 EXPECT_EQ(2, listener.invoked_); |
| 799 EXPECT_EQ(listener.invoked_ - 1, scheduler_invoked_); | 799 EXPECT_EQ(listener.invoked_ - 1, scheduler_invoked_); |
| 800 EXPECT_TRUE(base::MessageLoop::current()->IsIdleForTesting()); | 800 EXPECT_TRUE(base::MessageLoop::current()->IsIdleForTesting()); |
| 801 } | 801 } |
| 802 | 802 |
| 803 IN_PROC_BROWSER_TEST_F(AndroidUsbTraitsTest, TestDeviceCounting) { | 803 IN_PROC_BROWSER_TEST_F(AndroidUsbTraitsTest, TestDeviceCounting) { |
| 804 MockCountListenerForCheckingTraits listener(adb_bridge_); | 804 MockCountListenerForCheckingTraits listener(adb_bridge_); |
| 805 adb_bridge_->AddDeviceCountListener(&listener); | 805 adb_bridge_->AddDeviceCountListener(&listener); |
| 806 runner_->Run(); | 806 runner_->Run(); |
| 807 } | 807 } |
| OLD | NEW |