You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@logging.apache.org by gg...@apache.org on 2022/03/30 22:19:39 UTC

[logging-log4j2] branch release-2.x updated: Move comment.

This is an automated email from the ASF dual-hosted git repository.

ggregory pushed a commit to branch release-2.x
in repository https://gitbox.apache.org/repos/asf/logging-log4j2.git


The following commit(s) were added to refs/heads/release-2.x by this push:
     new 6586c5b  Move comment.
6586c5b is described below

commit 6586c5b15d0bb09e46a50ca672759efc3bced5c0
Author: Gary Gregory <ga...@gmail.com>
AuthorDate: Wed Mar 30 18:19:34 2022 -0400

    Move comment.
---
 .../log4j/message/LocalizedMessageFactoryTest.java | 32 +++++++++++-----------
 1 file changed, 16 insertions(+), 16 deletions(-)

diff --git a/log4j-api/src/test/java/org/apache/logging/log4j/message/LocalizedMessageFactoryTest.java b/log4j-api/src/test/java/org/apache/logging/log4j/message/LocalizedMessageFactoryTest.java
index a5f4db4..940ea23 100644
--- a/log4j-api/src/test/java/org/apache/logging/log4j/message/LocalizedMessageFactoryTest.java
+++ b/log4j-api/src/test/java/org/apache/logging/log4j/message/LocalizedMessageFactoryTest.java
@@ -37,22 +37,6 @@ public class LocalizedMessageFactoryTest {
 
     @Test
     public void testMessageMarkersNoDataYes() {
-        // Logs the following to the console sadly:
-        //
-        // ERROR StatusLogger Unable to format msg: C:/Program%20Files/Some%20Company/Some%20Product%20Name/
-        // java.util.UnknownFormatConversionException: Conversion = 'F'
-        //  at java.util.Formatter$FormatSpecifier.conversion(Formatter.java:2691)
-        //  at java.util.Formatter$FormatSpecifier.<init>(Formatter.java:2720)
-        //  at java.util.Formatter.parse(Formatter.java:2560)
-        //  at java.util.Formatter.format(Formatter.java:2501)
-        //  at java.util.Formatter.format(Formatter.java:2455)
-        //  at java.lang.String.format(String.java:2981)
-        //  at org.apache.logging.log4j.message.StringFormattedMessage.formatMessage(StringFormattedMessage.java:116)
-        //  at org.apache.logging.log4j.message.StringFormattedMessage.getFormattedMessage(StringFormattedMessage.java:88)
-        //  at org.apache.logging.log4j.message.FormattedMessage.getFormattedMessage(FormattedMessage.java:178)
-        //  at org.apache.logging.log4j.message.LocalizedMessage.getFormattedMessage(LocalizedMessage.java:196)
-        //  at org.apache.logging.log4j.message.LocalizedMessageFactoryTest.testNoMatchPercentInMessage(LocalizedMessageFactoryTest.java:60)
-        //
         final LocalizedMessageFactory localizedMessageFactory = new LocalizedMessageFactory(ResourceBundle.getBundle("MF", Locale.US));
         final Message message = localizedMessageFactory.newMessage("msg1", 1, "two");
         assertEquals("This is test number 1 with string argument two.", message.getFormattedMessage());
@@ -74,6 +58,22 @@ public class LocalizedMessageFactoryTest {
 
     @Test
     public void testNoMatchPercentInMessage() {
+        // Logs the following to the console sadly:
+        //
+        // ERROR StatusLogger Unable to format msg: C:/Program%20Files/Some%20Company/Some%20Product%20Name/
+        // java.util.UnknownFormatConversionException: Conversion = 'F'
+        //  at java.util.Formatter$FormatSpecifier.conversion(Formatter.java:2691)
+        //  at java.util.Formatter$FormatSpecifier.<init>(Formatter.java:2720)
+        //  at java.util.Formatter.parse(Formatter.java:2560)
+        //  at java.util.Formatter.format(Formatter.java:2501)
+        //  at java.util.Formatter.format(Formatter.java:2455)
+        //  at java.lang.String.format(String.java:2981)
+        //  at org.apache.logging.log4j.message.StringFormattedMessage.formatMessage(StringFormattedMessage.java:116)
+        //  at org.apache.logging.log4j.message.StringFormattedMessage.getFormattedMessage(StringFormattedMessage.java:88)
+        //  at org.apache.logging.log4j.message.FormattedMessage.getFormattedMessage(FormattedMessage.java:178)
+        //  at org.apache.logging.log4j.message.LocalizedMessage.getFormattedMessage(LocalizedMessage.java:196)
+        //  at org.apache.logging.log4j.message.LocalizedMessageFactoryTest.testNoMatchPercentInMessage(LocalizedMessageFactoryTest.java:60)
+        //
         final LocalizedMessageFactory localizedMessageFactory = new LocalizedMessageFactory(ResourceBundle.getBundle("MF", Locale.US));
         final Message message = localizedMessageFactory.newMessage("C:/Program%20Files/Some%20Company/Some%20Product%20Name/");
         assertEquals("C:/Program%20Files/Some%20Company/Some%20Product%20Name/", message.getFormattedMessage());