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

Side by Side Diff: chrome/browser/autocomplete/history_contents_provider_unittest.cc

Issue 7995: Move Time, TimeDelta and TimeTicks into namespace base. (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: Created 12 years, 2 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 | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2006-2008 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2006-2008 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 "base/file_util.h" 5 #include "base/file_util.h"
6 #include "base/path_service.h" 6 #include "base/path_service.h"
7 #include "base/string_util.h" 7 #include "base/string_util.h"
8 #include "chrome/browser/autocomplete/autocomplete.h" 8 #include "chrome/browser/autocomplete/autocomplete.h"
9 #include "chrome/browser/autocomplete/history_contents_provider.h" 9 #include "chrome/browser/autocomplete/history_contents_provider.h"
10 #include "chrome/browser/history/history.h" 10 #include "chrome/browser/history/history.h"
11 #include "chrome/test/testing_profile.h" 11 #include "chrome/test/testing_profile.h"
12 #include "testing/gtest/include/gtest/gtest.h" 12 #include "testing/gtest/include/gtest/gtest.h"
13 13
14 using base::Time;
15 using base::TimeDelta;
16
14 namespace { 17 namespace {
15 18
16 struct TestEntry { 19 struct TestEntry {
17 const char* url; 20 const char* url;
18 const wchar_t* title; 21 const wchar_t* title;
19 const wchar_t* body; 22 const wchar_t* body;
20 } test_entries[] = { 23 } test_entries[] = {
21 {"http://www.google.com/1", L"PAGEONE 1", L"FOO some body text"}, 24 {"http://www.google.com/1", L"PAGEONE 1", L"FOO some body text"},
22 {"http://www.google.com/2", L"PAGEONE 2", L"FOO some more blah blah"}, 25 {"http://www.google.com/2", L"PAGEONE 2", L"FOO some more blah blah"},
23 {"http://www.google.com/3", L"PAGETHREE 3", L"BAR some hello world for you"}, 26 {"http://www.google.com/3", L"PAGETHREE 3", L"BAR some hello world for you"},
(...skipping 154 matching lines...) Expand 10 before | Expand all | Expand 10 after
178 // We should two urls now, bookmark_url and http://www.google.com/3. 181 // We should two urls now, bookmark_url and http://www.google.com/3.
179 const ACMatches& m3 = matches(); 182 const ACMatches& m3 = matches();
180 ASSERT_EQ(2, m3.size()); 183 ASSERT_EQ(2, m3.size());
181 if (bookmark_url.spec() == WideToUTF8(m3[0].destination_url)) { 184 if (bookmark_url.spec() == WideToUTF8(m3[0].destination_url)) {
182 EXPECT_EQ(L"http://www.google.com/3", m3[1].destination_url); 185 EXPECT_EQ(L"http://www.google.com/3", m3[1].destination_url);
183 } else { 186 } else {
184 EXPECT_EQ(bookmark_url.spec(), WideToUTF8(m3[1].destination_url)); 187 EXPECT_EQ(bookmark_url.spec(), WideToUTF8(m3[1].destination_url));
185 EXPECT_EQ(L"http://www.google.com/3", m3[0].destination_url); 188 EXPECT_EQ(L"http://www.google.com/3", m3[0].destination_url);
186 } 189 }
187 } 190 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698