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

Side by Side Diff: chrome/browser/history/in_memory_url_index_unittest.cc

Issue 268673004: Move bookmarks' test support file to the bookmarks component (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@367839
Patch Set: Remove duplicated dependency 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
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 <algorithm> 5 #include <algorithm>
6 #include <fstream> 6 #include <fstream>
7 7
8 #include "base/auto_reset.h" 8 #include "base/auto_reset.h"
9 #include "base/file_util.h" 9 #include "base/file_util.h"
10 #include "base/files/file_path.h" 10 #include "base/files/file_path.h"
11 #include "base/files/scoped_temp_dir.h" 11 #include "base/files/scoped_temp_dir.h"
12 #include "base/message_loop/message_loop.h" 12 #include "base/message_loop/message_loop.h"
13 #include "base/path_service.h" 13 #include "base/path_service.h"
14 #include "base/strings/string16.h" 14 #include "base/strings/string16.h"
15 #include "base/strings/string_util.h" 15 #include "base/strings/string_util.h"
16 #include "base/strings/utf_string_conversions.h" 16 #include "base/strings/utf_string_conversions.h"
17 #include "chrome/browser/autocomplete/autocomplete_provider.h" 17 #include "chrome/browser/autocomplete/autocomplete_provider.h"
18 #include "chrome/browser/bookmarks/bookmark_model_factory.h" 18 #include "chrome/browser/bookmarks/bookmark_model_factory.h"
19 #include "chrome/browser/bookmarks/bookmark_test_helpers.h"
20 #include "chrome/browser/chrome_notification_types.h" 19 #include "chrome/browser/chrome_notification_types.h"
21 #include "chrome/browser/history/history_backend.h" 20 #include "chrome/browser/history/history_backend.h"
22 #include "chrome/browser/history/history_database.h" 21 #include "chrome/browser/history/history_database.h"
23 #include "chrome/browser/history/history_notifications.h" 22 #include "chrome/browser/history/history_notifications.h"
24 #include "chrome/browser/history/history_service.h" 23 #include "chrome/browser/history/history_service.h"
25 #include "chrome/browser/history/history_service_factory.h" 24 #include "chrome/browser/history/history_service_factory.h"
26 #include "chrome/browser/history/in_memory_url_index.h" 25 #include "chrome/browser/history/in_memory_url_index.h"
27 #include "chrome/browser/history/in_memory_url_index_types.h" 26 #include "chrome/browser/history/in_memory_url_index_types.h"
28 #include "chrome/browser/history/url_index_private_data.h" 27 #include "chrome/browser/history/url_index_private_data.h"
29 #include "chrome/common/chrome_paths.h" 28 #include "chrome/common/chrome_paths.h"
30 #include "chrome/test/base/history_index_restore_observer.h" 29 #include "chrome/test/base/history_index_restore_observer.h"
31 #include "chrome/test/base/testing_profile.h" 30 #include "chrome/test/base/testing_profile.h"
31 #include "components/bookmarks/core/test/bookmark_test_helpers.h"
32 #include "content/public/browser/notification_details.h" 32 #include "content/public/browser/notification_details.h"
33 #include "content/public/browser/notification_source.h" 33 #include "content/public/browser/notification_source.h"
34 #include "content/public/test/test_browser_thread.h" 34 #include "content/public/test/test_browser_thread.h"
35 #include "sql/transaction.h" 35 #include "sql/transaction.h"
36 #include "testing/gtest/include/gtest/gtest.h" 36 #include "testing/gtest/include/gtest/gtest.h"
37 37
38 using base::ASCIIToUTF16; 38 using base::ASCIIToUTF16;
39 using content::BrowserThread; 39 using content::BrowserThread;
40 40
41 // The test version of the history url database table ('url') is contained in 41 // The test version of the history url database table ('url') is contained in
(...skipping 1135 matching lines...) Expand 10 before | Expand all | Expand 10 after
1177 full_file_path.GetComponents(&actual_parts); 1177 full_file_path.GetComponents(&actual_parts);
1178 ASSERT_EQ(expected_parts.size(), actual_parts.size()); 1178 ASSERT_EQ(expected_parts.size(), actual_parts.size());
1179 size_t count = expected_parts.size(); 1179 size_t count = expected_parts.size();
1180 for (size_t i = 0; i < count; ++i) 1180 for (size_t i = 0; i < count; ++i)
1181 EXPECT_EQ(expected_parts[i], actual_parts[i]); 1181 EXPECT_EQ(expected_parts[i], actual_parts[i]);
1182 // Must clear the history_dir_ to satisfy the dtor's DCHECK. 1182 // Must clear the history_dir_ to satisfy the dtor's DCHECK.
1183 set_history_dir(base::FilePath()); 1183 set_history_dir(base::FilePath());
1184 } 1184 }
1185 1185
1186 } // namespace history 1186 } // namespace history
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698