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

Side by Side Diff: chrome/browser/geolocation/chrome_geolocation_permission_context_unittest.cc

Issue 14113053: chrome: Use base::MessageLoop. (Part 3) (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: rebase again Created 7 years, 6 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 <set> 5 #include <set>
6 #include <string> 6 #include <string>
7 #include <utility> 7 #include <utility>
8 8
9 #include "base/bind.h" 9 #include "base/bind.h"
10 #include "base/hash_tables.h" 10 #include "base/hash_tables.h"
(...skipping 131 matching lines...) Expand 10 before | Expand all | Expand 10 after
142 content::TestBrowserThread ui_thread_; 142 content::TestBrowserThread ui_thread_;
143 content::TestBrowserThread db_thread_; 143 content::TestBrowserThread db_thread_;
144 144
145 // A map between renderer child id and a pair represending the bridge id and 145 // A map between renderer child id and a pair represending the bridge id and
146 // whether the requested permission was allowed. 146 // whether the requested permission was allowed.
147 base::hash_map<int, std::pair<int, bool> > responses_; 147 base::hash_map<int, std::pair<int, bool> > responses_;
148 }; 148 };
149 149
150 GeolocationPermissionContextTests::GeolocationPermissionContextTests() 150 GeolocationPermissionContextTests::GeolocationPermissionContextTests()
151 : ChromeRenderViewHostTestHarness(), 151 : ChromeRenderViewHostTestHarness(),
152 ui_thread_(content::BrowserThread::UI, MessageLoop::current()), 152 ui_thread_(content::BrowserThread::UI, base::MessageLoop::current()),
153 db_thread_(content::BrowserThread::DB) { 153 db_thread_(content::BrowserThread::DB) {
154 } 154 }
155 155
156 GeolocationPermissionContextTests::~GeolocationPermissionContextTests() { 156 GeolocationPermissionContextTests::~GeolocationPermissionContextTests() {
157 } 157 }
158 158
159 GeolocationPermissionRequestID GeolocationPermissionContextTests::RequestID( 159 GeolocationPermissionRequestID GeolocationPermissionContextTests::RequestID(
160 int bridge_id) { 160 int bridge_id) {
161 return GeolocationPermissionRequestID( 161 return GeolocationPermissionRequestID(
162 web_contents()->GetRenderProcessHost()->GetID(), 162 web_contents()->GetRenderProcessHost()->GetID(),
(...skipping 537 matching lines...) Expand 10 before | Expand all | Expand 10 after
700 details.entry = web_contents()->GetController().GetLastCommittedEntry(); 700 details.entry = web_contents()->GetController().GetLastCommittedEntry();
701 EXPECT_FALSE(infobar_0->ShouldExpire(details)); 701 EXPECT_FALSE(infobar_0->ShouldExpire(details));
702 // Ensure the infobar will expire when we commit the pending navigation. 702 // Ensure the infobar will expire when we commit the pending navigation.
703 details.entry = web_contents()->GetController().GetActiveEntry(); 703 details.entry = web_contents()->GetController().GetActiveEntry();
704 EXPECT_TRUE(infobar_0->ShouldExpire(details)); 704 EXPECT_TRUE(infobar_0->ShouldExpire(details));
705 705
706 // Delete the tab contents. 706 // Delete the tab contents.
707 DeleteContents(); 707 DeleteContents();
708 delete infobar_0; 708 delete infobar_0;
709 } 709 }
OLDNEW
« no previous file with comments | « chrome/browser/geolocation/access_token_store_browsertest.cc ('k') | chrome/browser/geolocation/geolocation_browsertest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698