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

Side by Side Diff: components/dom_distiller/core/dom_distiller_test_util.cc

Issue 1879613003: Convert //components/dom_distiller from scoped_ptr to std::unique_ptr (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: rebase Created 4 years, 8 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 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/dom_distiller/core/dom_distiller_test_util.h" 5 #include "components/dom_distiller/core/dom_distiller_test_util.h"
6 6
7 #include "components/dom_distiller/core/dom_distiller_store.h" 7 #include "components/dom_distiller/core/dom_distiller_store.h"
8 #include "components/dom_distiller/core/fake_distiller.h" 8 #include "components/dom_distiller/core/fake_distiller.h"
9 9
10 using leveldb_proto::test::FakeDB; 10 using leveldb_proto::test::FakeDB;
(...skipping 76 matching lines...) Expand 10 before | Expand all | Expand 10 after
87 HasExpectedUpdates( 87 HasExpectedUpdates(
88 const std::vector<DomDistillerObserver::ArticleUpdate>& expected_updates) { 88 const std::vector<DomDistillerObserver::ArticleUpdate>& expected_updates) {
89 return testing::MakeMatcher(new ObserverUpdatesMatcher(expected_updates)); 89 return testing::MakeMatcher(new ObserverUpdatesMatcher(expected_updates));
90 } 90 }
91 91
92 // static 92 // static
93 DomDistillerStore* CreateStoreWithFakeDB( 93 DomDistillerStore* CreateStoreWithFakeDB(
94 FakeDB<ArticleEntry>* fake_db, 94 FakeDB<ArticleEntry>* fake_db,
95 const FakeDB<ArticleEntry>::EntryMap& store_model) { 95 const FakeDB<ArticleEntry>::EntryMap& store_model) {
96 return new DomDistillerStore( 96 return new DomDistillerStore(
97 scoped_ptr<leveldb_proto::ProtoDatabase<ArticleEntry> >(fake_db), 97 std::unique_ptr<leveldb_proto::ProtoDatabase<ArticleEntry>>(fake_db),
98 EntryMapToList(store_model), FakeDB<ArticleEntry>::DirectoryForTestDB()); 98 EntryMapToList(store_model), FakeDB<ArticleEntry>::DirectoryForTestDB());
99 } 99 }
100 100
101 } // namespace util 101 } // namespace util
102 } // namespace test 102 } // namespace test
103 } // namespace dom_distiller 103 } // namespace dom_distiller
OLDNEW
« no previous file with comments | « components/dom_distiller/core/dom_distiller_store_unittest.cc ('k') | components/dom_distiller/core/fake_distiller.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698