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

Side by Side Diff: net/flip/flip_network_transaction_unittest.cc

Issue 467031: Disabled ConnectFailure test due to flaky valgrind failures. (Closed)
Patch Set: Add bug link. Created 11 years 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
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2009 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2009 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/flip/flip_network_transaction.h" 5 #include "net/flip/flip_network_transaction.h"
6 6
7 #include "base/basictypes.h" 7 #include "base/basictypes.h"
8 #include "base/ref_counted.h" 8 #include "base/ref_counted.h"
9 #include "net/base/completion_callback.h" 9 #include "net/base/completion_callback.h"
10 #include "net/base/mock_host_resolver.h" 10 #include "net/base/mock_host_resolver.h"
(...skipping 862 matching lines...) Expand 10 before | Expand all | Expand 10 after
873 request.url = GURL("http://www.google.com/"); 873 request.url = GURL("http://www.google.com/");
874 request.load_flags = 0; 874 request.load_flags = 0;
875 scoped_refptr<DelayedSocketData> data( 875 scoped_refptr<DelayedSocketData> data(
876 new DelayedSocketData(reads, kChunks, writes.get())); 876 new DelayedSocketData(reads, kChunks, writes.get()));
877 TransactionHelperResult out = TransactionHelper(request, data.get()); 877 TransactionHelperResult out = TransactionHelper(request, data.get());
878 EXPECT_EQ(OK, out.rv); 878 EXPECT_EQ(OK, out.rv);
879 EXPECT_EQ("HTTP/1.1 200 OK", out.status_line); 879 EXPECT_EQ("HTTP/1.1 200 OK", out.status_line);
880 EXPECT_EQ("hello!", out.response_data); 880 EXPECT_EQ("hello!", out.response_data);
881 } 881 }
882 882
883 TEST_F(FlipNetworkTransactionTest, ConnectFailure) { 883 // Disabled due to flaky mac (and possibly linux) valgrind errors.
884 // http://crbug.com/29471
885 TEST_F(FlipNetworkTransactionTest, DISABLED_ConnectFailure) {
884 MockConnect connects[] = { 886 MockConnect connects[] = {
885 MockConnect(true, ERR_NAME_NOT_RESOLVED), 887 MockConnect(true, ERR_NAME_NOT_RESOLVED),
886 MockConnect(false, ERR_NAME_NOT_RESOLVED), 888 MockConnect(false, ERR_NAME_NOT_RESOLVED),
887 MockConnect(true, ERR_INTERNET_DISCONNECTED), 889 MockConnect(true, ERR_INTERNET_DISCONNECTED),
888 MockConnect(false, ERR_INTERNET_DISCONNECTED) 890 MockConnect(false, ERR_INTERNET_DISCONNECTED)
889 }; 891 };
890 892
891 for (size_t index = 0; index < arraysize(connects); ++index) { 893 for (size_t index = 0; index < arraysize(connects); ++index) {
892 MockWrite writes[] = { 894 MockWrite writes[] = {
893 MockWrite(true, reinterpret_cast<const char*>(kGetSyn), 895 MockWrite(true, reinterpret_cast<const char*>(kGetSyn),
(...skipping 14 matching lines...) Expand all
908 request.url = GURL("http://www.google.com/"); 910 request.url = GURL("http://www.google.com/");
909 request.load_flags = 0; 911 request.load_flags = 0;
910 scoped_refptr<DelayedSocketData> data( 912 scoped_refptr<DelayedSocketData> data(
911 new DelayedSocketData(connects[index], reads, 1, writes)); 913 new DelayedSocketData(connects[index], reads, 1, writes));
912 TransactionHelperResult out = TransactionHelper(request, data.get()); 914 TransactionHelperResult out = TransactionHelper(request, data.get());
913 EXPECT_EQ(connects[index].result, out.rv); 915 EXPECT_EQ(connects[index].result, out.rv);
914 } 916 }
915 } 917 }
916 918
917 } // namespace net 919 } // namespace net
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698