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

Side by Side Diff: components/autofill/content/browser/wallet/wallet_test_util.cc

Issue 23930002: [rAc] Reset the user's selection to the new default when the default Wallet item changes. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Factor out common functionality Created 7 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 | Annotate | Revision Log
« no previous file with comments | « components/autofill/content/browser/wallet/wallet_test_util.h ('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 2013 The Chromium Authors. All rights reserved. 1 // Copyright 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 "components/autofill/content/browser/wallet/wallet_test_util.h" 5 #include "components/autofill/content/browser/wallet/wallet_test_util.h"
6 6
7 #include <string> 7 #include <string>
8 #include <vector> 8 #include <vector>
9 9
10 #include "base/strings/string16.h" 10 #include "base/strings/string16.h"
(...skipping 207 matching lines...) Expand 10 before | Expand all | Expand 10 after
218 "default_address_id")); 218 "default_address_id"));
219 } 219 }
220 220
221 scoped_ptr<Address> GetTestNonDefaultShippingAddress() { 221 scoped_ptr<Address> GetTestNonDefaultShippingAddress() {
222 scoped_ptr<Address> address = GetTestShippingAddress(); 222 scoped_ptr<Address> address = GetTestShippingAddress();
223 address->set_object_id("address_id"); 223 address->set_object_id("address_id");
224 return address.Pass(); 224 return address.Pass();
225 } 225 }
226 226
227 scoped_ptr<WalletItems> GetTestWalletItems() { 227 scoped_ptr<WalletItems> GetTestWalletItems() {
228 return GetTestWalletItemsWithDefaultIds("default_instrument_id",
229 "default_address_id");
230 }
231
232 scoped_ptr<WalletItems> GetTestWalletItemsWithDefaultIds(
233 const std::string& default_instrument_id,
234 const std::string& default_address_id) {
228 return scoped_ptr<WalletItems>( 235 return scoped_ptr<WalletItems>(
229 new wallet::WalletItems(std::vector<RequiredAction>(), 236 new wallet::WalletItems(std::vector<RequiredAction>(),
230 "google_transaction_id", 237 "google_transaction_id",
231 "default_instrument_id", 238 default_instrument_id,
232 "default_address_id", 239 default_address_id,
233 "obfuscated_gaia_id")); 240 "obfuscated_gaia_id"));
234 } 241 }
235 242
236 } // namespace wallet 243 } // namespace wallet
237 } // namespace autofill 244 } // namespace autofill
OLDNEW
« no previous file with comments | « components/autofill/content/browser/wallet/wallet_test_util.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698