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

Side by Side Diff: chromeos/network/shill_property_handler_unittest.cc

Issue 388963002: Get rid of the rest of CreateStringValue (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: fix bad rebase Created 6 years, 5 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
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 "chromeos/network/shill_property_handler.h" 5 #include "chromeos/network/shill_property_handler.h"
6 6
7 #include <map> 7 #include <map>
8 #include <set> 8 #include <set>
9 #include <string> 9 #include <string>
10 10
(...skipping 414 matching lines...) Expand 10 before | Expand all | Expand 10 after
425 TEST_F(ShillPropertyHandlerTest, ShillPropertyHandlerIPConfigPropertyChanged) { 425 TEST_F(ShillPropertyHandlerTest, ShillPropertyHandlerIPConfigPropertyChanged) {
426 // Set the properties for an IP Config object. 426 // Set the properties for an IP Config object.
427 const std::string kTestIPConfigPath("test_ip_config_path"); 427 const std::string kTestIPConfigPath("test_ip_config_path");
428 428
429 base::StringValue ip_address("192.168.1.1"); 429 base::StringValue ip_address("192.168.1.1");
430 DBusThreadManager::Get()->GetShillIPConfigClient()->SetProperty( 430 DBusThreadManager::Get()->GetShillIPConfigClient()->SetProperty(
431 dbus::ObjectPath(kTestIPConfigPath), 431 dbus::ObjectPath(kTestIPConfigPath),
432 shill::kAddressProperty, ip_address, 432 shill::kAddressProperty, ip_address,
433 base::Bind(&DoNothingWithCallStatus)); 433 base::Bind(&DoNothingWithCallStatus));
434 base::ListValue dns_servers; 434 base::ListValue dns_servers;
435 dns_servers.Append(base::Value::CreateStringValue("192.168.1.100")); 435 dns_servers.Append(new base::StringValue("192.168.1.100"));
436 dns_servers.Append(base::Value::CreateStringValue("192.168.1.101")); 436 dns_servers.Append(new base::StringValue("192.168.1.101"));
437 DBusThreadManager::Get()->GetShillIPConfigClient()->SetProperty( 437 DBusThreadManager::Get()->GetShillIPConfigClient()->SetProperty(
438 dbus::ObjectPath(kTestIPConfigPath), 438 dbus::ObjectPath(kTestIPConfigPath),
439 shill::kNameServersProperty, dns_servers, 439 shill::kNameServersProperty, dns_servers,
440 base::Bind(&DoNothingWithCallStatus)); 440 base::Bind(&DoNothingWithCallStatus));
441 base::FundamentalValue prefixlen(8); 441 base::FundamentalValue prefixlen(8);
442 DBusThreadManager::Get()->GetShillIPConfigClient()->SetProperty( 442 DBusThreadManager::Get()->GetShillIPConfigClient()->SetProperty(
443 dbus::ObjectPath(kTestIPConfigPath), 443 dbus::ObjectPath(kTestIPConfigPath),
444 shill::kPrefixlenProperty, prefixlen, 444 shill::kPrefixlenProperty, prefixlen,
445 base::Bind(&DoNothingWithCallStatus)); 445 base::Bind(&DoNothingWithCallStatus));
446 base::StringValue gateway("192.0.0.1"); 446 base::StringValue gateway("192.0.0.1");
(...skipping 57 matching lines...) Expand 10 before | Expand all | Expand 10 after
504 shill_property_handler_->UpdateManagerProperties(); 504 shill_property_handler_->UpdateManagerProperties();
505 message_loop_.RunUntilIdle(); 505 message_loop_.RunUntilIdle();
506 EXPECT_EQ(1, listener_->list_updates(shill::kServiceCompleteListProperty)); 506 EXPECT_EQ(1, listener_->list_updates(shill::kServiceCompleteListProperty));
507 EXPECT_EQ(1, listener_->initial_property_updates( 507 EXPECT_EQ(1, listener_->initial_property_updates(
508 shill::kServiceCompleteListProperty)[kTestServicePath2]); 508 shill::kServiceCompleteListProperty)[kTestServicePath2]);
509 EXPECT_EQ(1, listener_->property_updates( 509 EXPECT_EQ(1, listener_->property_updates(
510 shill::kServiceCompleteListProperty)[kTestServicePath2]); 510 shill::kServiceCompleteListProperty)[kTestServicePath2]);
511 } 511 }
512 512
513 } // namespace chromeos 513 } // namespace chromeos
OLDNEW
« no previous file with comments | « chromeos/network/onc/onc_translator_shill_to_onc.cc ('k') | components/metrics/persisted_logs.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698