| OLD | NEW |
| 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 Loading... |
| 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 |
| OLD | NEW |