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

Side by Side Diff: content/test/test_navigation_observer.cc

Issue 10807047: Create content\public\test\test_utils.h to hold common test classes that are used by unit and brows… (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: Created 8 years, 5 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
« no previous file with comments | « content/test/content_browser_test_utils.cc ('k') | content/test/test_utils.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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 "content/public/test/test_navigation_observer.h" 5 #include "content/public/test/test_navigation_observer.h"
6 6
7 #include "base/bind.h" 7 #include "base/bind.h"
8 #include "base/message_loop.h" 8 #include "base/message_loop.h"
9 #include "base/run_loop.h" 9 #include "base/run_loop.h"
10 #include "content/public/browser/notification_service.h" 10 #include "content/public/browser/notification_service.h"
11 #include "content/public/browser/notification_types.h" 11 #include "content/public/browser/notification_types.h"
12 #include "content/public/browser/render_view_host_observer.h" 12 #include "content/public/browser/render_view_host_observer.h"
13 #include "content/public/test/browser_test_utils.h"
14 #include "content/public/test/js_injection_ready_observer.h" 13 #include "content/public/test/js_injection_ready_observer.h"
14 #include "content/public/test/test_utils.h"
15 #include "testing/gtest/include/gtest/gtest.h" 15 #include "testing/gtest/include/gtest/gtest.h"
16 16
17 namespace content { 17 namespace content {
18 18
19 // This class observes |render_view_host| and calls OnJsInjectionReady() of 19 // This class observes |render_view_host| and calls OnJsInjectionReady() of
20 // |js_injection_ready_observer| when the time is right to inject JavaScript 20 // |js_injection_ready_observer| when the time is right to inject JavaScript
21 // into the page. 21 // into the page.
22 class TestNavigationObserver::RVHOSendJS : public RenderViewHostObserver { 22 class TestNavigationObserver::RVHOSendJS : public RenderViewHostObserver {
23 public: 23 public:
24 RVHOSendJS(RenderViewHost* render_view_host, 24 RVHOSendJS(RenderViewHost* render_view_host,
(...skipping 117 matching lines...) Expand 10 before | Expand all | Expand 10 after
142 rvho_send_js_.reset(new RVHOSendJS( 142 rvho_send_js_.reset(new RVHOSendJS(
143 Source<RenderViewHost>(source).ptr(), 143 Source<RenderViewHost>(source).ptr(),
144 js_injection_ready_observer_)); 144 js_injection_ready_observer_));
145 break; 145 break;
146 default: 146 default:
147 NOTREACHED(); 147 NOTREACHED();
148 } 148 }
149 } 149 }
150 150
151 } // namespace content 151 } // namespace content
OLDNEW
« no previous file with comments | « content/test/content_browser_test_utils.cc ('k') | content/test/test_utils.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698