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

Unified Diff: components/cryptauth/remote_device_test_util.cc

Issue 2576283002: [Chrome OS Tether] Create BleAdvertisementDeviceQueue. (Closed)
Patch Set: Created 4 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 side-by-side diff with in-line comments
Download patch
Index: components/cryptauth/remote_device_test_util.cc
diff --git a/components/cryptauth/remote_device_test_util.cc b/components/cryptauth/remote_device_test_util.cc
new file mode 100644
index 0000000000000000000000000000000000000000..73fe0928ec807a97fca2595ad252b96ad794c787
--- /dev/null
+++ b/components/cryptauth/remote_device_test_util.cc
@@ -0,0 +1,23 @@
+// Copyright 2016 The Chromium Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+#include "components/cryptauth/remote_device_test_util.h"
+
+#include "base/base64.h"
+
+namespace cryptauth {
+
+std::vector<RemoteDevice> GenerateTestRemoteDevices(size_t num_to_create) {
+ std::vector<RemoteDevice> generated_devices;
+
+ for (size_t i = 0; i < num_to_create; i++) {
+ RemoteDevice device;
+ device.public_key = "publicKey" + std::to_string(i);
+ generated_devices.push_back(device);
+ }
+
+ return generated_devices;
+}
+
+} // namespace cryptauth

Powered by Google App Engine
This is Rietveld 408576698