"Fossies" - the Fresh Open Source Software Archive  

Source code changes of the file "log4j-core/src/test/java/org/apache/logging/log4j/core/appender/mom/JmsAppenderTest.java" between
apache-log4j-2.12.3-src.tar.gz and apache-log4j-2.12.4-src.tar.gz

About: Apache Log4j 2 is a logging library for Java. Source distribution (Java).
Caution: Release 2.12.3 is the last 2.x release to support Java 7 (Java 8 users should use 2.17.0 or greater) and have fixed a critical remote code execution vulnerability (CVE-2021-44228).

JmsAppenderTest.java  (apache-log4j-2.12.3-src):JmsAppenderTest.java  (apache-log4j-2.12.4-src)
skipping to change at line 51 skipping to change at line 51
import org.apache.logging.log4j.Level; import org.apache.logging.log4j.Level;
import org.apache.logging.log4j.categories.Appenders; import org.apache.logging.log4j.categories.Appenders;
import org.apache.logging.log4j.core.LogEvent; import org.apache.logging.log4j.core.LogEvent;
import org.apache.logging.log4j.core.impl.Log4jLogEvent; import org.apache.logging.log4j.core.impl.Log4jLogEvent;
import org.apache.logging.log4j.junit.JndiRule; import org.apache.logging.log4j.junit.JndiRule;
import org.apache.logging.log4j.junit.LoggerContextRule; import org.apache.logging.log4j.junit.LoggerContextRule;
import org.apache.logging.log4j.message.Message; import org.apache.logging.log4j.message.Message;
import org.apache.logging.log4j.message.SimpleMessage; import org.apache.logging.log4j.message.SimpleMessage;
import org.apache.logging.log4j.message.StringMapMessage; import org.apache.logging.log4j.message.StringMapMessage;
import org.junit.AfterClass;
import org.junit.Before; import org.junit.Before;
import org.junit.BeforeClass; import org.junit.BeforeClass;
import org.junit.Rule; import org.junit.Rule;
import org.junit.Test; import org.junit.Test;
import org.junit.experimental.categories.Category; import org.junit.experimental.categories.Category;
import org.junit.rules.RuleChain; import org.junit.rules.RuleChain;
@Category(Appenders.Jms.class) @Category(Appenders.Jms.class)
public class JmsAppenderTest { public class JmsAppenderTest {
skipping to change at line 87 skipping to change at line 88
private final TextMessage textMessage = mock(TextMessage.class); private final TextMessage textMessage = mock(TextMessage.class);
private final ObjectMessage objectMessage = mock(ObjectMessage.class); private final ObjectMessage objectMessage = mock(ObjectMessage.class);
private final MapMessage mapMessage = mock(MapMessage.class); private final MapMessage mapMessage = mock(MapMessage.class);
private final JndiRule jndiRule = new JndiRule(createBindings()); private final JndiRule jndiRule = new JndiRule(createBindings());
private final LoggerContextRule ctx = new LoggerContextRule("JmsAppenderTest .xml"); private final LoggerContextRule ctx = new LoggerContextRule("JmsAppenderTest .xml");
@Rule @Rule
public RuleChain rules = RuleChain.outerRule(jndiRule).around(ctx); public RuleChain rules = RuleChain.outerRule(jndiRule).around(ctx);
@BeforeClass @AfterClass
public static void afterClass() throws Exception { public static void afterClass() throws Exception {
System.clearProperty("log4j2.enableJndiJms"); System.clearProperty("log4j2.enableJndiJms");
} }
@BeforeClass @BeforeClass
public static void beforeClass() throws Exception { public static void beforeClass() throws Exception {
System.setProperty("log4j2.enableJndiJms", "true"); System.setProperty("log4j2.enableJndiJms", "true");
} }
public JmsAppenderTest() throws Exception { public JmsAppenderTest() throws Exception {
 End of changes. 2 change blocks. 
1 lines changed or deleted 2 lines changed or added

Home  |  About  |  Features  |  All  |  Newest  |  Dox  |  Diffs  |  RSS Feeds  |  Screenshots  |  Comments  |  Imprint  |  Privacy  |  HTTP(S)