Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(422)

Side by Side Diff: device/hid/input_service_linux_unittest.cc

Issue 250803005: Devices without devnode are filtered out. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Rebase. Created 6 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « device/hid/input_service_linux.cc ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 <vector> 5 #include <vector>
6 6
7 #include "base/message_loop/message_loop.h" 7 #include "base/message_loop/message_loop.h"
8 #include "device/hid/input_service_linux.cc" 8 #include "device/hid/input_service_linux.h"
9 #include "testing/gtest/include/gtest/gtest.h" 9 #include "testing/gtest/include/gtest/gtest.h"
10 10
11 namespace device { 11 namespace device {
12 12
13 TEST(InputServiceLinux, Simple) { 13 TEST(InputServiceLinux, Simple) {
14 base::MessageLoopForIO message_loop; 14 base::MessageLoopForIO message_loop;
15 InputServiceLinux* service = InputServiceLinux::GetInstance(); 15 InputServiceLinux* service = InputServiceLinux::GetInstance();
16 16
17 ASSERT_TRUE(service); 17 ASSERT_TRUE(service);
18 std::vector<InputServiceLinux::InputDeviceInfo> devices; 18 std::vector<InputServiceLinux::InputDeviceInfo> devices;
19 service->GetDevices(&devices); 19 service->GetDevices(&devices);
20 for (size_t i = 0; i < devices.size(); ++i) 20 for (size_t i = 0; i < devices.size(); ++i)
21 ASSERT_TRUE(!devices[i].id.empty()); 21 ASSERT_TRUE(!devices[i].id.empty());
22 } 22 }
23 23
24 } // namespace device 24 } // namespace device
OLDNEW
« no previous file with comments | « device/hid/input_service_linux.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698