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

Side by Side Diff: device/bluetooth/dbus/bluetooth_dbus_client_bundle_unittest.cc

Issue 1347193004: Refactor DBusThreadManager to split away BT clients. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 3 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
OLDNEW
(Empty)
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
3 // found in the LICENSE file.
4
5 #include "device/bluetooth/dbus/bluetooth_dbus_client_bundle.h"
6
7 #include "base/basictypes.h"
8 #include "base/compiler_specific.h"
9 #include "testing/gtest/include/gtest/gtest.h"
10
11 namespace bluez {
12
13 TEST(DBusClientBundleTest, UnstubFlagParser) {
14 EXPECT_EQ(0, DBusClientBundle::ParseUnstubList("foo"));
15
16 EXPECT_EQ(BluetoothDBusClientBundle::BLUETOOTH,
17 DBusClientBundle::ParseUnstubList("BLUETOOTH"));
18
19 EXPECT_EQ(BluetoothDBusClientBundle::BLUETOOTH,
20 DBusClientBundle::ParseUnstubList("bluetooth"));
21
22 EXPECT_EQ(
23 DBusClientBundle::CRAS | DBusClientBundle::CROS_DISKS |
24 DBusClientBundle::DEBUG_DAEMON | DBusClientBundle::SHILL,
25 DBusClientBundle::ParseUnstubList("Cras,Cros_Disks,debug_daemon,Shill"));
26
27 EXPECT_EQ(DBusClientBundle::CRAS | DBusClientBundle::CROS_DISKS |
28 DBusClientBundle::DEBUG_DAEMON | DBusClientBundle::SHILL,
29 DBusClientBundle::ParseUnstubList(
30 "foo,Cras,Cros_Disks,debug_daemon,Shill"));
31 }
32
33 } // namespace bluez
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698