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

Side by Side Diff: net/url_request/url_fetcher_impl_unittest.cc

Issue 10878003: Refactoring for merging WebSocket test server to net::TestServer (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: reflect Ryan's review Created 8 years, 4 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 "net/url_request/url_fetcher_impl.h" 5 #include "net/url_request/url_fetcher_impl.h"
6 6
7 #include <string> 7 #include <string>
8 8
9 #include "base/bind.h" 9 #include "base/bind.h"
10 #include "base/file_util.h" 10 #include "base/file_util.h"
(...skipping 972 matching lines...) Expand 10 before | Expand all | Expand 10 after
983 983
984 MessageLoop::current()->Run(); 984 MessageLoop::current()->Run();
985 } 985 }
986 986
987 #if defined(OS_MACOSX) 987 #if defined(OS_MACOSX)
988 // SIGSEGV on Mac: http://crbug.com/60426 988 // SIGSEGV on Mac: http://crbug.com/60426
989 TEST_F(URLFetcherBadHTTPSTest, DISABLED_BadHTTPSTest) { 989 TEST_F(URLFetcherBadHTTPSTest, DISABLED_BadHTTPSTest) {
990 #else 990 #else
991 TEST_F(URLFetcherBadHTTPSTest, BadHTTPSTest) { 991 TEST_F(URLFetcherBadHTTPSTest, BadHTTPSTest) {
992 #endif 992 #endif
993 TestServer::HTTPSOptions https_options( 993 TestServer::SSLOptions ssl_options(
994 TestServer::HTTPSOptions::CERT_EXPIRED); 994 TestServer::SSLOptions::CERT_EXPIRED);
995 TestServer test_server(https_options, FilePath(kDocRoot)); 995 TestServer test_server(TestServer::TYPE_HTTPS,
996 ssl_options,
997 FilePath(kDocRoot));
996 ASSERT_TRUE(test_server.Start()); 998 ASSERT_TRUE(test_server.Start());
997 999
998 CreateFetcher(test_server.GetURL("defaultresponse")); 1000 CreateFetcher(test_server.GetURL("defaultresponse"));
999 MessageLoop::current()->Run(); 1001 MessageLoop::current()->Run();
1000 } 1002 }
1001 1003
1002 #if defined(OS_MACOSX) 1004 #if defined(OS_MACOSX)
1003 // SIGSEGV on Mac: http://crbug.com/60426 1005 // SIGSEGV on Mac: http://crbug.com/60426
1004 TEST_F(URLFetcherCancelTest, DISABLED_ReleasesContext) { 1006 TEST_F(URLFetcherCancelTest, DISABLED_ReleasesContext) {
1005 #else 1007 #else
(...skipping 236 matching lines...) Expand 10 before | Expand all | Expand 10 after
1242 MessageLoop::current()->Run(); // OnURLFetchComplete() will Quit(). 1244 MessageLoop::current()->Run(); // OnURLFetchComplete() will Quit().
1243 1245
1244 MessageLoop::current()->RunAllPending(); 1246 MessageLoop::current()->RunAllPending();
1245 ASSERT_FALSE(file_util::PathExists(file_path_)) 1247 ASSERT_FALSE(file_util::PathExists(file_path_))
1246 << file_path_.value() << " not removed."; 1248 << file_path_.value() << " not removed.";
1247 } 1249 }
1248 1250
1249 } // namespace 1251 } // namespace
1250 1252
1251 } // namespace net 1253 } // namespace net
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698