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

Side by Side Diff: chrome/browser/visitedlink/visitedlink_unittest.cc

Issue 8437002: Move BrowserThread to content namespace. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: A few updates. Created 9 years, 1 month 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) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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 <cstdio> 5 #include <cstdio>
6 #include <string> 6 #include <string>
7 #include <vector> 7 #include <vector>
8 8
9 #include "base/file_util.h" 9 #include "base/file_util.h"
10 #include "base/message_loop.h" 10 #include "base/message_loop.h"
11 #include "base/path_service.h" 11 #include "base/path_service.h"
12 #include "base/process_util.h" 12 #include "base/process_util.h"
13 #include "base/shared_memory.h" 13 #include "base/shared_memory.h"
14 #include "base/string_util.h" 14 #include "base/string_util.h"
15 #include "chrome/browser/visitedlink/visitedlink_event_listener.h" 15 #include "chrome/browser/visitedlink/visitedlink_event_listener.h"
16 #include "chrome/browser/visitedlink/visitedlink_master.h" 16 #include "chrome/browser/visitedlink/visitedlink_master.h"
17 #include "chrome/common/render_messages.h" 17 #include "chrome/common/render_messages.h"
18 #include "chrome/renderer/visitedlink_slave.h" 18 #include "chrome/renderer/visitedlink_slave.h"
19 #include "chrome/test/base/chrome_render_view_host_test_harness.h" 19 #include "chrome/test/base/chrome_render_view_host_test_harness.h"
20 #include "chrome/test/base/testing_profile.h" 20 #include "chrome/test/base/testing_profile.h"
21 #include "content/browser/renderer_host/browser_render_process_host.h" 21 #include "content/browser/renderer_host/browser_render_process_host.h"
22 #include "content/public/browser/notification_service.h" 22 #include "content/public/browser/notification_service.h"
23 #include "content/public/browser/notification_types.h" 23 #include "content/public/browser/notification_types.h"
24 #include "content/test/test_browser_thread.h" 24 #include "content/test/test_browser_thread.h"
25 #include "googleurl/src/gurl.h" 25 #include "googleurl/src/gurl.h"
26 #include "testing/gtest/include/gtest/gtest.h" 26 #include "testing/gtest/include/gtest/gtest.h"
27 27
28 using content::BrowserThread;
29
28 namespace { 30 namespace {
29 31
30 // a nice long URL that we can append numbers to to get new URLs 32 // a nice long URL that we can append numbers to to get new URLs
31 const char g_test_prefix[] = 33 const char g_test_prefix[] =
32 "http://www.google.com/products/foo/index.html?id=45028640526508376&seq="; 34 "http://www.google.com/products/foo/index.html?id=45028640526508376&seq=";
33 const int g_test_count = 1000; 35 const int g_test_count = 1000;
34 36
35 // Returns a test URL for index |i| 37 // Returns a test URL for index |i|
36 GURL TestURL(int i) { 38 GURL TestURL(int i) {
37 return GURL(StringPrintf("%s%d", g_test_prefix, i)); 39 return GURL(StringPrintf("%s%d", g_test_prefix, i));
(...skipping 680 matching lines...) Expand 10 before | Expand all | Expand 10 after
718 EXPECT_EQ(1, profile()->add_event_count()); 720 EXPECT_EQ(1, profile()->add_event_count());
719 EXPECT_EQ(0, profile()->reset_event_count()); 721 EXPECT_EQ(0, profile()->reset_event_count());
720 722
721 // Activate the tab. 723 // Activate the tab.
722 rvh()->WasRestored(); 724 rvh()->WasRestored();
723 725
724 // We should have only one more reset event. 726 // We should have only one more reset event.
725 EXPECT_EQ(1, profile()->add_event_count()); 727 EXPECT_EQ(1, profile()->add_event_count());
726 EXPECT_EQ(1, profile()->reset_event_count()); 728 EXPECT_EQ(1, profile()->reset_event_count());
727 } 729 }
OLDNEW
« no previous file with comments | « chrome/browser/visitedlink/visitedlink_master.cc ('k') | chrome/browser/web_applications/web_app.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698