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

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

Issue 108603005: Update uses of Value in chromeos/, cloud_print/, components/, content/ to use the base:: namespace. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years 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/network/network_device_handler_impl.cc ('k') | chromeos/network/network_util.h » ('j') | 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) 2013 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2013 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/network_state.h" 5 #include "chromeos/network/network_state.h"
6 6
7 #include "base/basictypes.h" 7 #include "base/basictypes.h"
8 #include "base/memory/scoped_ptr.h" 8 #include "base/memory/scoped_ptr.h"
9 #include "base/strings/string_number_conversions.h" 9 #include "base/strings/string_number_conversions.h"
10 #include "base/values.h" 10 #include "base/values.h"
(...skipping 19 matching lines...) Expand all
30 virtual bool GetAsString(std::string* out_value) const OVERRIDE { 30 virtual bool GetAsString(std::string* out_value) const OVERRIDE {
31 if (out_value) 31 if (out_value)
32 *out_value = value_; 32 *out_value = value_;
33 return true; 33 return true;
34 } 34 }
35 35
36 virtual TestStringValue* DeepCopy() const OVERRIDE { 36 virtual TestStringValue* DeepCopy() const OVERRIDE {
37 return new TestStringValue(value_); 37 return new TestStringValue(value_);
38 } 38 }
39 39
40 virtual bool Equals(const Value* other) const OVERRIDE { 40 virtual bool Equals(const base::Value* other) const OVERRIDE {
41 if (other->GetType() != GetType()) 41 if (other->GetType() != GetType())
42 return false; 42 return false;
43 std::string lhs, rhs; 43 std::string lhs, rhs;
44 return GetAsString(&lhs) && other->GetAsString(&rhs) && lhs == rhs; 44 return GetAsString(&lhs) && other->GetAsString(&rhs) && lhs == rhs;
45 } 45 }
46 46
47 private: 47 private:
48 std::string value_; 48 std::string value_;
49 }; 49 };
50 50
(...skipping 86 matching lines...) Expand 10 before | Expand all | Expand 10 after
137 137
138 std::string wifi_hex_result = "This is HEX SSID!"; 138 std::string wifi_hex_result = "This is HEX SSID!";
139 std::string wifi_hex = 139 std::string wifi_hex =
140 base::HexEncode(wifi_hex_result.c_str(), wifi_hex_result.length()); 140 base::HexEncode(wifi_hex_result.c_str(), wifi_hex_result.length());
141 EXPECT_FALSE(SetStringProperty(shill::kWifiHexSsid, wifi_hex)); 141 EXPECT_FALSE(SetStringProperty(shill::kWifiHexSsid, wifi_hex));
142 EXPECT_TRUE(SignalInitialPropertiesReceived()); 142 EXPECT_TRUE(SignalInitialPropertiesReceived());
143 EXPECT_EQ(network_state_.name(), wifi_hex_result); 143 EXPECT_EQ(network_state_.name(), wifi_hex_result);
144 } 144 }
145 145
146 } // namespace chromeos 146 } // namespace chromeos
OLDNEW
« no previous file with comments | « chromeos/network/network_device_handler_impl.cc ('k') | chromeos/network/network_util.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698