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

Unified Diff: chrome/test/live_sync/live_bookmarks_sync_test.cc

Issue 214047: Allow an entire InProcessBrowserTest subclass to configure the host resolver ... (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: '' Created 11 years, 3 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 side-by-side diff with in-line comments
Download patch
Index: chrome/test/live_sync/live_bookmarks_sync_test.cc
===================================================================
--- chrome/test/live_sync/live_bookmarks_sync_test.cc (revision 26713)
+++ chrome/test/live_sync/live_bookmarks_sync_test.cc (working copy)
@@ -82,4 +82,18 @@
return ProfileManager::CreateProfile(path, name, L"", L"");
}
+void LiveBookmarksSyncTest::SetUpInProcessBrowserTestFixture() {
+ // We don't take a reference to |resolver|, but mock_host_resolver_override_
+ // does, so effectively assumes ownership.
+ net::RuleBasedHostResolverProc* resolver =
+ new net::RuleBasedHostResolverProc(host_resolver());
+ resolver->AllowDirectLookup("*.google.com");
+ mock_host_resolver_override_.reset(
+ new net::ScopedDefaultHostResolverProc(resolver));
+}
+
+void LiveBookmarksSyncTest::TearDownInProcessBrowserTestFixture() {
+ mock_host_resolver_override_.reset();
+}
+
#endif // CHROME_PERSONALIZATION
« no previous file with comments | « chrome/test/live_sync/live_bookmarks_sync_test.h ('k') | chrome/test/live_sync/two_client_live_bookmarks_sync_test.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698