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

Unified Diff: components/history/core/browser/in_memory_url_index_types_unittest.cc

Issue 896093004: Cleanup usage of history namespace in components/history (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 10 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 side-by-side diff with in-line comments
Download patch
Index: components/history/core/browser/in_memory_url_index_types_unittest.cc
diff --git a/components/history/core/browser/in_memory_url_index_types_unittest.cc b/components/history/core/browser/in_memory_url_index_types_unittest.cc
index b140491a7bb96c044cce52296875a7b9f1090f64..c10f1c0043cf22e5061d4188b572063b9e81fbce 100644
--- a/components/history/core/browser/in_memory_url_index_types_unittest.cc
+++ b/components/history/core/browser/in_memory_url_index_types_unittest.cc
@@ -126,12 +126,12 @@ TEST_F(InMemoryURLIndexTypesTest, StaticFunctions) {
TEST_F(InMemoryURLIndexTypesTest, OffsetsAndTermMatches) {
// Test OffsetsFromTermMatches
- history::TermMatches matches_a;
- matches_a.push_back(history::TermMatch(1, 1, 2));
- matches_a.push_back(history::TermMatch(2, 4, 3));
- matches_a.push_back(history::TermMatch(3, 9, 1));
- matches_a.push_back(history::TermMatch(3, 10, 1));
- matches_a.push_back(history::TermMatch(4, 14, 5));
+ TermMatches matches_a;
+ matches_a.push_back(TermMatch(1, 1, 2));
+ matches_a.push_back(TermMatch(2, 4, 3));
+ matches_a.push_back(TermMatch(3, 9, 1));
+ matches_a.push_back(TermMatch(3, 10, 1));
+ matches_a.push_back(TermMatch(4, 14, 5));
std::vector<size_t> offsets = OffsetsFromTermMatches(matches_a);
const size_t expected_offsets_a[] = {1, 3, 4, 7, 9, 10, 10, 11, 14, 19};
ASSERT_EQ(offsets.size(), arraysize(expected_offsets_a));
@@ -140,8 +140,7 @@ TEST_F(InMemoryURLIndexTypesTest, OffsetsAndTermMatches) {
// Test ReplaceOffsetsInTermMatches
offsets[4] = base::string16::npos; // offset of third term
- history::TermMatches matches_b =
- ReplaceOffsetsInTermMatches(matches_a, offsets);
+ TermMatches matches_b = ReplaceOffsetsInTermMatches(matches_a, offsets);
const size_t expected_offsets_b[] = {1, 4, 10, 14};
ASSERT_EQ(arraysize(expected_offsets_b), matches_b.size());
for (size_t i = 0; i < matches_b.size(); ++i)
« no previous file with comments | « components/history/core/browser/in_memory_url_index_types.h ('k') | components/history/core/browser/page_usage_data.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698