--- a/test/jdk/java/net/httpclient/CancelledResponse.java Fri Feb 23 16:25:32 2018 +0000
+++ b/test/jdk/java/net/httpclient/CancelledResponse.java Sat Feb 24 11:27:11 2018 +0000
@@ -160,11 +160,11 @@
try {
if (async) {
out.println("send async: " + request);
- cf1 = client.sendAsync(request, asString(body, cancelled));
+ cf1 = client.sendAsync(request, ofString(body, cancelled));
r = cf1.get();
} else { // sync
out.println("send sync: " + request);
- r = client.send(request, asString(body, cancelled));
+ r = client.send(request, ofString(body, cancelled));
}
} catch (CancelException c1) {
System.out.println("Got expected exception: " + c1);
@@ -294,7 +294,7 @@
}
}
- BodyHandler<String> asString(String expected, AtomicBoolean cancelled) {
+ BodyHandler<String> ofString(String expected, AtomicBoolean cancelled) {
return new CancellingHandler(expected, cancelled);
}