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

Side by Side Diff: chrome/browser/ui/intents/web_intent_picker_controller_browsertest.cc

Issue 10822030: Move ui_test_utils::RunMessageLoop to test_utils so that it can be reused by content_browsertests. (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
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 <algorithm> 5 #include <algorithm>
6 #include <iterator> 6 #include <iterator>
7 7
8 #include "base/bind.h" 8 #include "base/bind.h"
9 #include "base/callback.h" 9 #include "base/callback.h"
10 #include "base/memory/scoped_ptr.h" 10 #include "base/memory/scoped_ptr.h"
(...skipping 125 matching lines...) Expand 10 before | Expand all | Expand 10 after
136 num_extension_icons_changed_++; 136 num_extension_icons_changed_++;
137 } 137 }
138 virtual void OnInlineDisposition( 138 virtual void OnInlineDisposition(
139 const string16& title, const GURL& url) OVERRIDE { 139 const string16& title, const GURL& url) OVERRIDE {
140 num_inline_disposition_++; 140 num_inline_disposition_++;
141 } 141 }
142 142
143 void Wait() { 143 void Wait() {
144 if (!pending_async_completed_) { 144 if (!pending_async_completed_) {
145 message_loop_started_ = true; 145 message_loop_started_ = true;
146 ui_test_utils::RunMessageLoop(); 146 content::RunMessageLoop();
147 pending_async_completed_ = false; 147 pending_async_completed_ = false;
148 } 148 }
149 } 149 }
150 150
151 void StopWaiting() { 151 void StopWaiting() {
152 pending_async_completed_ = true; 152 pending_async_completed_ = true;
153 if (message_loop_started_) 153 if (message_loop_started_)
154 MessageLoop::current()->Quit(); 154 MessageLoop::current()->Quit();
155 } 155 }
156 156
(...skipping 466 matching lines...) Expand 10 before | Expand all | Expand 10 after
623 623
624 EXPECT_EQ(2, picker_.num_installed_services_); 624 EXPECT_EQ(2, picker_.num_installed_services_);
625 625
626 // The tab is shown immediately without needing to call OnServiceChosen. 626 // The tab is shown immediately without needing to call OnServiceChosen.
627 ASSERT_EQ(2, browser()->tab_count()); 627 ASSERT_EQ(2, browser()->tab_count());
628 EXPECT_EQ(GURL(kServiceURL1), 628 EXPECT_EQ(GURL(kServiceURL1),
629 chrome::GetActiveWebContents(browser())->GetURL()); 629 chrome::GetActiveWebContents(browser())->GetURL());
630 630
631 EXPECT_TRUE(dispatcher.dispatched_); 631 EXPECT_TRUE(dispatcher.dispatched_);
632 } 632 }
OLDNEW
« no previous file with comments | « chrome/browser/task_manager/task_manager_browsertest_util.cc ('k') | chrome/browser/ui/omnibox/omnibox_view_browsertest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698