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

Side by Side Diff: components/search_provider_logos/logo_tracker_unittest.cc

Issue 296053005: Fix more cases of unreachable code on Windows (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 years, 7 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
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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/search_provider_logos/logo_tracker.h" 5 #include "components/search_provider_logos/logo_tracker.h"
6 6
7 #include <vector> 7 #include <vector>
8 8
9 #include "base/base64.h" 9 #include "base/base64.h"
10 #include "base/bind.h" 10 #include "base/bind.h"
(...skipping 206 matching lines...) Expand 10 before | Expand all | Expand 10 after
217 virtual const LogoMetadata* GetCachedLogoMetadataInternal() { 217 virtual const LogoMetadata* GetCachedLogoMetadataInternal() {
218 return metadata_.get(); 218 return metadata_.get();
219 } 219 }
220 220
221 virtual void SetCachedLogoInternal(const EncodedLogo* logo) { 221 virtual void SetCachedLogoInternal(const EncodedLogo* logo) {
222 logo_.reset(logo ? new EncodedLogo(*logo) : NULL); 222 logo_.reset(logo ? new EncodedLogo(*logo) : NULL);
223 metadata_.reset(logo ? new LogoMetadata(logo->metadata) : NULL); 223 metadata_.reset(logo ? new LogoMetadata(logo->metadata) : NULL);
224 } 224 }
225 225
226 virtual scoped_ptr<EncodedLogo> GetCachedLogo() OVERRIDE { 226 virtual scoped_ptr<EncodedLogo> GetCachedLogo() OVERRIDE {
227 OnGetCachedLogo();
227 return make_scoped_ptr(logo_ ? new EncodedLogo(*logo_) : NULL); 228 return make_scoped_ptr(logo_ ? new EncodedLogo(*logo_) : NULL);
228 OnGetCachedLogo();
229 } 229 }
230 230
231 private: 231 private:
232 scoped_ptr<LogoMetadata> metadata_; 232 scoped_ptr<LogoMetadata> metadata_;
233 scoped_ptr<EncodedLogo> logo_; 233 scoped_ptr<EncodedLogo> logo_;
234 }; 234 };
235 235
236 class MockLogoObserver : public LogoObserver { 236 class MockLogoObserver : public LogoObserver {
237 public: 237 public:
238 virtual ~MockLogoObserver() {} 238 virtual ~MockLogoObserver() {}
(...skipping 421 matching lines...) Expand 10 before | Expand all | Expand 10 after
660 MockLogoObserver listener2; 660 MockLogoObserver listener2;
661 listener2.ExpectFreshLogo(&logo); 661 listener2.ExpectFreshLogo(&logo);
662 logo_tracker_->GetLogo(&listener2); 662 logo_tracker_->GetLogo(&listener2);
663 663
664 base::RunLoop().RunUntilIdle(); 664 base::RunLoop().RunUntilIdle();
665 } 665 }
666 666
667 } // namespace 667 } // namespace
668 668
669 } // namespace search_provider_logos 669 } // namespace search_provider_logos
OLDNEW
« no previous file with comments | « chrome/test/gpu/gpu_feature_browsertest.cc ('k') | content/browser/renderer_host/render_widget_host_view_aura.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698