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

Side by Side Diff: components/sync/device_info/device_count_metrics_provider_unittest.cc

Issue 2310683002: Remove most ScopedVector usage from c/b/extensions. (Closed)
Patch Set: remove scoped_vector includes Created 4 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
OLDNEW
1 // Copyright 2016 The Chromium Authors. All rights reserved. 1 // Copyright 2016 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/sync/device_info/device_count_metrics_provider.h" 5 #include "components/sync/device_info/device_count_metrics_provider.h"
6 6
7 #include <memory> 7 #include <memory>
8 #include <string> 8 #include <string>
9 #include <vector> 9 #include <vector>
10 10
(...skipping 10 matching lines...) Expand all
21 class FakeTracker : public DeviceInfoTracker { 21 class FakeTracker : public DeviceInfoTracker {
22 public: 22 public:
23 explicit FakeTracker(const int count) : count_(count) {} 23 explicit FakeTracker(const int count) : count_(count) {}
24 24
25 // DeviceInfoTracker 25 // DeviceInfoTracker
26 bool IsSyncing() const override { return false; } 26 bool IsSyncing() const override { return false; }
27 std::unique_ptr<DeviceInfo> GetDeviceInfo( 27 std::unique_ptr<DeviceInfo> GetDeviceInfo(
28 const std::string& client_id) const override { 28 const std::string& client_id) const override {
29 return std::unique_ptr<DeviceInfo>(); 29 return std::unique_ptr<DeviceInfo>();
30 } 30 }
31 ScopedVector<DeviceInfo> GetAllDeviceInfo() const override { 31 std::vector<std::unique_ptr<DeviceInfo>> GetAllDeviceInfo() const override {
32 return ScopedVector<DeviceInfo>(); 32 return std::vector<std::unique_ptr<DeviceInfo>>();
33 } 33 }
34 void AddObserver(Observer* observer) override {} 34 void AddObserver(Observer* observer) override {}
35 void RemoveObserver(Observer* observer) override {} 35 void RemoveObserver(Observer* observer) override {}
36 int CountActiveDevices() const override { return count_; } 36 int CountActiveDevices() const override { return count_; }
37 37
38 private: 38 private:
39 int count_; 39 int count_;
40 }; 40 };
41 41
42 } // namespace 42 } // namespace
(...skipping 52 matching lines...) Expand 10 before | Expand all | Expand 10 after
95 } 95 }
96 96
97 TEST_F(DeviceCountMetricsProviderTest, VeryLarge) { 97 TEST_F(DeviceCountMetricsProviderTest, VeryLarge) {
98 AddTracker(123456789); 98 AddTracker(123456789);
99 TestProvider(100); 99 TestProvider(100);
100 } 100 }
101 101
102 } // namespace 102 } // namespace
103 103
104 } // namespace sync_driver 104 } // namespace sync_driver
OLDNEW
« no previous file with comments | « chrome/browser/extensions/window_open_apitest.cc ('k') | components/sync/device_info/device_info_service.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698