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

Side by Side Diff: components/cronet/android/api/src/org/chromium/net/UrlRequestException.java

Issue 2506653003: Instrument CronetUrlRequestTest#testThrowOrCancelInOnCanceled flaky test (Closed)
Patch Set: Spelling fix Created 4 years, 1 month 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 | components/cronet/android/test/javatests/src/org/chromium/net/BidirectionalStreamTest.java » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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 package org.chromium.net; 5 package org.chromium.net;
6 6
7 import java.io.IOException; 7 import java.io.IOException;
8 8
9 /** 9 /**
10 * Exception passed to {@link UrlRequest.Callback#onFailed UrlRequest.Callback.o nFailed()} when: 10 * Exception passed to {@link UrlRequest.Callback#onFailed UrlRequest.Callback.o nFailed()} when:
(...skipping 143 matching lines...) Expand 10 before | Expand all | Expand 10 after
154 default: 154 default:
155 return false; 155 return false;
156 case ERROR_NETWORK_CHANGED: 156 case ERROR_NETWORK_CHANGED:
157 case ERROR_TIMED_OUT: 157 case ERROR_TIMED_OUT:
158 case ERROR_CONNECTION_CLOSED: 158 case ERROR_CONNECTION_CLOSED:
159 case ERROR_CONNECTION_TIMED_OUT: 159 case ERROR_CONNECTION_TIMED_OUT:
160 case ERROR_CONNECTION_RESET: 160 case ERROR_CONNECTION_RESET:
161 return true; 161 return true;
162 } 162 }
163 } 163 }
164
165 @Override
166 public String getMessage() {
167 StringBuilder b = new StringBuilder(super.getMessage());
168 b.append(", ErrorCode=").append(mErrorCode);
169 if (mCronetInternalErrorCode != 0) {
170 b.append(", InternalErrorCode=").append(mCronetInternalErrorCode);
171 }
172 b.append(", Retryable=").append(immediatelyRetryable());
173 return b.toString();
174 }
164 } 175 }
OLDNEW
« no previous file with comments | « no previous file | components/cronet/android/test/javatests/src/org/chromium/net/BidirectionalStreamTest.java » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698