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 "chrome/browser/importer/profile_writer.h" | 5 #include "chrome/browser/importer/profile_writer.h" |
6 | 6 |
7 #include <stddef.h> | 7 #include <stddef.h> |
8 | 8 |
9 #include <string> | 9 #include <string> |
10 | 10 |
11 #include "base/macros.h" | 11 #include "base/macros.h" |
| 12 #include "base/message_loop/message_loop.h" |
12 #include "base/run_loop.h" | 13 #include "base/run_loop.h" |
13 #include "base/strings/utf_string_conversions.h" | 14 #include "base/strings/utf_string_conversions.h" |
14 #include "chrome/browser/bookmarks/bookmark_model_factory.h" | 15 #include "chrome/browser/bookmarks/bookmark_model_factory.h" |
15 #include "chrome/browser/history/history_service_factory.h" | 16 #include "chrome/browser/history/history_service_factory.h" |
16 #include "chrome/browser/importer/importer_unittest_utils.h" | 17 #include "chrome/browser/importer/importer_unittest_utils.h" |
17 #include "chrome/common/importer/imported_bookmark_entry.h" | 18 #include "chrome/common/importer/imported_bookmark_entry.h" |
18 #include "chrome/test/base/testing_profile.h" | 19 #include "chrome/test/base/testing_profile.h" |
19 #include "components/bookmarks/browser/bookmark_model.h" | 20 #include "components/bookmarks/browser/bookmark_model.h" |
20 #include "components/bookmarks/browser/bookmark_utils.h" | 21 #include "components/bookmarks/browser/bookmark_utils.h" |
21 #include "components/bookmarks/browser/titled_url_match.h" | 22 #include "components/bookmarks/browser/titled_url_match.h" |
(...skipping 179 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
201 new TestProfileWriter(&profile)); | 202 new TestProfileWriter(&profile)); |
202 profile_writer->AddHistoryPage(pages_, history::SOURCE_FIREFOX_IMPORTED); | 203 profile_writer->AddHistoryPage(pages_, history::SOURCE_FIREFOX_IMPORTED); |
203 VerifyHistoryCount(&profile); | 204 VerifyHistoryCount(&profile); |
204 size_t original_history_count = history_count_; | 205 size_t original_history_count = history_count_; |
205 history_count_ = 0; | 206 history_count_ = 0; |
206 | 207 |
207 profile_writer->AddHistoryPage(pages_, history::SOURCE_FIREFOX_IMPORTED); | 208 profile_writer->AddHistoryPage(pages_, history::SOURCE_FIREFOX_IMPORTED); |
208 VerifyHistoryCount(&profile); | 209 VerifyHistoryCount(&profile); |
209 EXPECT_EQ(original_history_count, history_count_); | 210 EXPECT_EQ(original_history_count, history_count_); |
210 } | 211 } |
OLD | NEW |