Skip to content

Commit ee25441

Browse files
committed
8353847: Remove extra args to System.out.printf in open/test/jdk/java/net/httpclient tests
Backport-of: f94a4f7accd11161912ec2cdae6e290d0957666a
1 parent 93c3567 commit ee25441

File tree

3 files changed

+10
-10
lines changed

3 files changed

+10
-10
lines changed

test/jdk/java/net/httpclient/AsyncShutdownNow.java

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright (c) 2023, Oracle and/or its affiliates. All rights reserved.
2+
* Copyright (c) 2023, 2025, Oracle and/or its affiliates. All rights reserved.
33
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
44
*
55
* This code is free software; you can redistribute it and/or modify it
@@ -208,7 +208,7 @@ void testConcurrent(String uriString) throws Exception {
208208
Thread.sleep(sleep);
209209
}
210210
if (i == step) {
211-
out.printf("%d: shutting down client now%n", i, sleep);
211+
out.printf("%d: shutting down client now%n", i);
212212
client.shutdownNow();
213213
}
214214
var cf = bodyCF.exceptionally((t) -> {
@@ -304,7 +304,7 @@ void testSequential(String uriString) throws Exception {
304304
Thread.sleep(sleep);
305305
}
306306
if (i == step) {
307-
out.printf("%d: shutting down client now%n", i, sleep);
307+
out.printf("%d: shutting down client now%n", i);
308308
client.shutdownNow();
309309
}
310310
bodyCF.handle((r, t) -> {

test/jdk/java/net/httpclient/HttpClientShutdown.java

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright (c) 2023, Oracle and/or its affiliates. All rights reserved.
2+
* Copyright (c) 2023, 2025, Oracle and/or its affiliates. All rights reserved.
33
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
44
*
55
* This code is free software; you can redistribute it and/or modify it
@@ -192,7 +192,7 @@ ExchangeResult<T> assertResponseState() {
192192
out.println(now() + step + ": Got response: " + response);
193193
assertEquals(response.statusCode(), 200);
194194
} catch (AssertionError error) {
195-
out.printf(now() + "%s: Closing body due to assertion - %s", error);
195+
out.printf(now() + "%s: Closing body due to assertion - %s", step, error);
196196
ensureClosed(this);
197197
throw error;
198198
}
@@ -276,7 +276,7 @@ void testConcurrent(String uriString) throws Exception {
276276
continue;
277277
}
278278
if (i == step) {
279-
out.printf(now() + "%d: shutting down client%n", i, sleep);
279+
out.printf(now() + "%d: shutting down client%n", i);
280280
client.shutdown();
281281
}
282282
var cf = bodyCF.exceptionally((t) -> {
@@ -375,7 +375,7 @@ void testSequential(String uriString) throws Exception {
375375
continue;
376376
}
377377
if (i == step) {
378-
out.printf(now() + "%d: shutting down client%n", i, sleep);
378+
out.printf(now() + "%d: shutting down client%n", i);
379379
client.shutdown();
380380
}
381381
bodyCF.handle((r, t) -> {

test/jdk/java/net/httpclient/ShutdownNow.java

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright (c) 2023, Oracle and/or its affiliates. All rights reserved.
2+
* Copyright (c) 2023, 2025, Oracle and/or its affiliates. All rights reserved.
33
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
44
*
55
* This code is free software; you can redistribute it and/or modify it
@@ -182,7 +182,7 @@ void testConcurrent(String uriString) throws Exception {
182182
Thread.sleep(sleep);
183183
}
184184
if (i == step) {
185-
out.printf("%d: shutting down client now%n", i, sleep);
185+
out.printf("%d: shutting down client now%n", i);
186186
client.shutdownNow();
187187
}
188188
final int si = i;
@@ -238,7 +238,7 @@ void testSequential(String uriString) throws Exception {
238238
Thread.sleep(sleep);
239239
}
240240
if (i == step) {
241-
out.printf("%d: shutting down client now%n", i, sleep);
241+
out.printf("%d: shutting down client now%n", i);
242242
client.shutdownNow();
243243
}
244244
final int si = i;

0 commit comments

Comments
 (0)