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

Side by Side Diff: content/browser/geolocation/network_location_provider_unittest.cc

Issue 631053003: Replacing the OVERRIDE with override and FINAL with final in content/browser/geolocation (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Resolved mac issue Created 6 years, 2 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 (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 "base/json/json_reader.h" 5 #include "base/json/json_reader.h"
6 #include "base/json/json_writer.h" 6 #include "base/json/json_writer.h"
7 #include "base/memory/scoped_ptr.h" 7 #include "base/memory/scoped_ptr.h"
8 #include "base/strings/string_number_conversions.h" 8 #include "base/strings/string_number_conversions.h"
9 #include "base/strings/string_util.h" 9 #include "base/strings/string_util.h"
10 #include "base/strings/stringprintf.h" 10 #include "base/strings/stringprintf.h"
(...skipping 48 matching lines...) Expand 10 before | Expand all | Expand 10 after
59 59
60 static MockWifiDataProvider* CreateInstance() { 60 static MockWifiDataProvider* CreateInstance() {
61 CHECK(!instance_); 61 CHECK(!instance_);
62 instance_ = new MockWifiDataProvider; 62 instance_ = new MockWifiDataProvider;
63 return instance_; 63 return instance_;
64 } 64 }
65 65
66 MockWifiDataProvider() : start_calls_(0), stop_calls_(0), got_data_(true) {} 66 MockWifiDataProvider() : start_calls_(0), stop_calls_(0), got_data_(true) {}
67 67
68 // WifiDataProvider implementation. 68 // WifiDataProvider implementation.
69 virtual void StartDataProvider() OVERRIDE { 69 virtual void StartDataProvider() override {
70 ++start_calls_; 70 ++start_calls_;
71 } 71 }
72 72
73 virtual void StopDataProvider() OVERRIDE { 73 virtual void StopDataProvider() override {
74 ++stop_calls_; 74 ++stop_calls_;
75 } 75 }
76 76
77 virtual bool GetData(WifiData* data_out) OVERRIDE { 77 virtual bool GetData(WifiData* data_out) override {
78 CHECK(data_out); 78 CHECK(data_out);
79 *data_out = data_; 79 *data_out = data_;
80 return got_data_; 80 return got_data_;
81 } 81 }
82 82
83 void SetData(const WifiData& new_data) { 83 void SetData(const WifiData& new_data) {
84 got_data_ = true; 84 got_data_ = true;
85 const bool differs = data_.DiffersSignificantly(new_data); 85 const bool differs = data_.DiffersSignificantly(new_data);
86 data_ = new_data; 86 data_ = new_data;
87 if (differs) 87 if (differs)
(...skipping 462 matching lines...) Expand 10 before | Expand all | Expand 10 after
550 EXPECT_TRUE(cache.FindPosition(CreateReferenceWifiScanData(1))); 550 EXPECT_TRUE(cache.FindPosition(CreateReferenceWifiScanData(1)));
551 } else { 551 } else {
552 const int evicted = i - kCacheSize; 552 const int evicted = i - kCacheSize;
553 EXPECT_FALSE(cache.FindPosition(CreateReferenceWifiScanData(evicted))); 553 EXPECT_FALSE(cache.FindPosition(CreateReferenceWifiScanData(evicted)));
554 EXPECT_TRUE(cache.FindPosition(CreateReferenceWifiScanData(evicted + 1))); 554 EXPECT_TRUE(cache.FindPosition(CreateReferenceWifiScanData(evicted + 1)));
555 } 555 }
556 } 556 }
557 } 557 }
558 558
559 } // namespace content 559 } // namespace content
OLDNEW
« no previous file with comments | « content/browser/geolocation/network_location_provider.h ('k') | content/browser/geolocation/network_location_request.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698