Skip to content

Commit e89a20e

Browse files
laeubimarcphilipp
andauthored
Update junit-platform-reporting/src/main/java/org/junit/platform/reporting/open/xml/OpenTestReportGeneratingListener.java
Co-authored-by: Marc Philipp <[email protected]>
1 parent 7a1bd13 commit e89a20e

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

junit-platform-reporting/src/main/java/org/junit/platform/reporting/open/xml/OpenTestReportGeneratingListener.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -150,7 +150,7 @@ private DocumentWriter<Events> createDocumentWriter(ConfigurationParameters conf
150150
return config.get(SOCKET_PROPERTY_NAME, Integer::valueOf) //
151151
.map(port -> {
152152
try {
153-
Socket socket = new Socket("localhost", port);
153+
Socket socket = new Socket(InetAddress.getLoopbackAddress(), port);
154154
Writer writer = new OutputStreamWriter(socket.getOutputStream(), StandardCharsets.UTF_8);
155155
return Events.createDocumentWriter(namespaceRegistry, writer);
156156
}

0 commit comments

Comments
 (0)