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

Side by Side Diff: content/public/test/browser_test_utils.h

Issue 1008913002: Remove RenderViewHost parameter from WebContentsObserver::Did{Start|Stop}Loading. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebase Created 5 years, 9 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 #ifndef CONTENT_PUBLIC_TEST_BROWSER_TEST_UTILS_H_ 5 #ifndef CONTENT_PUBLIC_TEST_BROWSER_TEST_UTILS_H_
6 #define CONTENT_PUBLIC_TEST_BROWSER_TEST_UTILS_H_ 6 #define CONTENT_PUBLIC_TEST_BROWSER_TEST_UTILS_H_
7 7
8 #include <queue> 8 #include <queue>
9 #include <string> 9 #include <string>
10 #include <vector> 10 #include <vector>
(...skipping 252 matching lines...) Expand 10 before | Expand all | Expand 10 after
263 // Adds another title to watch for. 263 // Adds another title to watch for.
264 void AlsoWaitForTitle(const base::string16& expected_title); 264 void AlsoWaitForTitle(const base::string16& expected_title);
265 265
266 // Waits until the title matches either expected_title or one of the titles 266 // Waits until the title matches either expected_title or one of the titles
267 // added with AlsoWaitForTitle. Returns the value of the most recently 267 // added with AlsoWaitForTitle. Returns the value of the most recently
268 // observed matching title. 268 // observed matching title.
269 const base::string16& WaitAndGetTitle() WARN_UNUSED_RESULT; 269 const base::string16& WaitAndGetTitle() WARN_UNUSED_RESULT;
270 270
271 private: 271 private:
272 // Overridden WebContentsObserver methods. 272 // Overridden WebContentsObserver methods.
273 void DidStopLoading(RenderViewHost* render_view_host) override; 273 void DidStopLoading() override;
274 void TitleWasSet(NavigationEntry* entry, bool explicit_set) override; 274 void TitleWasSet(NavigationEntry* entry, bool explicit_set) override;
275 275
276 void TestTitle(); 276 void TestTitle();
277 277
278 std::vector<base::string16> expected_titles_; 278 std::vector<base::string16> expected_titles_;
279 scoped_refptr<MessageLoopRunner> message_loop_runner_; 279 scoped_refptr<MessageLoopRunner> message_loop_runner_;
280 280
281 // The most recently observed expected title, if any. 281 // The most recently observed expected title, if any.
282 base::string16 observed_title_; 282 base::string16 observed_title_;
283 283
(...skipping 105 matching lines...) Expand 10 before | Expand all | Expand 10 after
389 WebContents* web_contents_; 389 WebContents* web_contents_;
390 scoped_ptr<RenderViewCreatedObserver> child_observer_; 390 scoped_ptr<RenderViewCreatedObserver> child_observer_;
391 scoped_refptr<MessageLoopRunner> runner_; 391 scoped_refptr<MessageLoopRunner> runner_;
392 392
393 DISALLOW_COPY_AND_ASSIGN(WebContentsAddedObserver); 393 DISALLOW_COPY_AND_ASSIGN(WebContentsAddedObserver);
394 }; 394 };
395 395
396 } // namespace content 396 } // namespace content
397 397
398 #endif // CONTENT_PUBLIC_TEST_BROWSER_TEST_UTILS_H_ 398 #endif // CONTENT_PUBLIC_TEST_BROWSER_TEST_UTILS_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698