perry2of5 commented on a change in pull request #491:
URL: https://github.com/apache/logging-log4j2/pull/491#discussion_r628334682



##########
File path: 
log4j-layout-template-json/src/test/java/org/apache/logging/log4j/layout/template/json/JsonTemplateLayoutNullEventDelimiterTest.java
##########
@@ -23,38 +23,38 @@
 import org.awaitility.Awaitility;
 import org.junit.jupiter.api.Test;
 
+import java.io.BufferedWriter;
 import java.io.ByteArrayOutputStream;
 import java.io.EOFException;
+import java.io.File;
+import java.io.FileOutputStream;
 import java.io.IOException;
 import java.io.InputStream;
+import java.io.OutputStreamWriter;
+import java.nio.file.Files;
+import java.nio.charset.StandardCharsets;
 import java.net.BindException;
 import java.net.ServerSocket;
 import java.net.Socket;
 import java.time.Duration;
 
 public class JsonTemplateLayoutNullEventDelimiterTest {
-
-    // Set the configuration.
-    static {
-        System.setProperty(
-                "log4j.configurationFile",
-                "nullEventDelimitedJsonTemplateLayoutLogging.xml");
-    }
-
-    // Note that this port is hardcoded in the configuration file too!
-    private static final int PORT = 50514;
-
     @Test
     public void test() throws Exception {
-
+        File tempConfig = 
File.createTempFile("nullEventDelimitedJsonTemplateLayoutLogging", ".xml");

Review comment:
       This is a good change to make. I thought I already made it as commit 
d70da9e7214d7baa3643363b849e5ec124b7b748. I see that commit in my branch, did 
it not show up here? I'm still figuring out git so any advice on how I should 
have made this work.




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
[email protected]


Reply via email to