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

Side by Side Diff: chromeos/dbus/introspectable_client_unittest.cc

Issue 10440013: Move chromeos::GetInterfacesFromIntrospectResult into IntrospectableClient (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 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 | « chromeos/dbus/introspectable_client.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 (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/chromeos/dbus/introspect_util.h" 5 #include "chromeos/dbus/introspectable_client.h"
6 6
7 #include "testing/gtest/include/gtest/gtest.h" 7 #include "testing/gtest/include/gtest/gtest.h"
8 8
9 namespace { 9 namespace {
10 10
11 const char kXmlData[] = 11 const char kXmlData[] =
12 "<!DOCTYPE node PUBLIC " 12 "<!DOCTYPE node PUBLIC "
13 "\"-//freedesktop//DTD D-BUS Object Introspection 1.0//EN\" " 13 "\"-//freedesktop//DTD D-BUS Object Introspection 1.0//EN\" "
14 "\"http://www.freedesktop.org/standards/dbus/1.0/introspect.dtd\">\n" 14 "\"http://www.freedesktop.org/standards/dbus/1.0/introspect.dtd\">\n"
15 "<node>\n" 15 "<node>\n"
(...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after
48 " <arg type=\"s\"/>\n" 48 " <arg type=\"s\"/>\n"
49 " <arg type=\"v\"/>\n" 49 " <arg type=\"v\"/>\n"
50 " </signal>\n" 50 " </signal>\n"
51 " </interface>\n" 51 " </interface>\n"
52 "</node>"; 52 "</node>";
53 53
54 } // namespace 54 } // namespace
55 55
56 namespace chromeos { 56 namespace chromeos {
57 57
58 TEST(IntrospectUtilTest, GetInterfacesFromIntrospectResult) { 58 TEST(IntrospectableClientTest, GetInterfacesFromIntrospectResult) {
59 std::vector<std::string> interfaces = 59 std::vector<std::string> interfaces =
60 GetInterfacesFromIntrospectResult(kXmlData); 60 IntrospectableClient::GetInterfacesFromIntrospectResult(kXmlData);
61 61
62 ASSERT_EQ(3U, interfaces.size()); 62 ASSERT_EQ(3U, interfaces.size());
63 EXPECT_EQ("org.freedesktop.DBus.Introspectable", interfaces[0]); 63 EXPECT_EQ("org.freedesktop.DBus.Introspectable", interfaces[0]);
64 EXPECT_EQ("org.bluez.Device", interfaces[1]); 64 EXPECT_EQ("org.bluez.Device", interfaces[1]);
65 EXPECT_EQ("org.bluez.Input", interfaces[2]); 65 EXPECT_EQ("org.bluez.Input", interfaces[2]);
66 } 66 }
67 67
68 } // namespace chromeos 68 } // namespace chromeos
OLDNEW
« no previous file with comments | « chromeos/dbus/introspectable_client.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698