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

rombert pushed a commit to branch master
in repository 
https://gitbox.apache.org/repos/asf/sling-org-apache-sling-commons-log-webconsole.git

commit bc28ae82ecba4dd22056d934e50ae9d32d32373d
Author: Chetan Mehrotra <[email protected]>
AuthorDate: Mon Feb 20 10:36:05 2017 +0000

    SLING-6530 - ITWebConsoleRemote fails intermittently
    
    The logback file was not having required custom tags hence the test cannot 
work and at times passes due to assertions passing due to fails log message 
entries
    
    git-svn-id: https://svn.apache.org/repos/asf/sling/trunk@1783736 
13f79535-47bb-0310-9956-ffa450edef68
---
 .../org/apache/sling/commons/log/webconsole/ITWebConsoleRemote.java | 6 +++---
 src/test/resources/test-webconsole-remote.xml                       | 5 +++++
 2 files changed, 8 insertions(+), 3 deletions(-)

diff --git 
a/src/test/java/org/apache/sling/commons/log/webconsole/ITWebConsoleRemote.java 
b/src/test/java/org/apache/sling/commons/log/webconsole/ITWebConsoleRemote.java
index fb76661..b8eef9a 100644
--- 
a/src/test/java/org/apache/sling/commons/log/webconsole/ITWebConsoleRemote.java
+++ 
b/src/test/java/org/apache/sling/commons/log/webconsole/ITWebConsoleRemote.java
@@ -110,13 +110,13 @@ public class ITWebConsoleRemote extends LogTestBase {
         String text = page.asText();
 
         //Filter name should be part of Filter table
-        assertTrue(text.contains("WebConsoleTestTurboFilter"));
+        assertThat(text, containsString("WebConsoleTestTurboFilter"));
 
         //Console name should be part of console table
-        assertTrue(text.contains("WebConsoleTestAppender"));
+        assertThat(text, containsString("WebConsoleTestAppender"));
 
         //Should show file name testremote.log
-        assertTrue(text.contains("testremote.log"));
+        assertThat(text, containsString("testremote.log"));
     }
 
     @Test
diff --git a/src/test/resources/test-webconsole-remote.xml 
b/src/test/resources/test-webconsole-remote.xml
index 23a2536..18cedaf 100644
--- a/src/test/resources/test-webconsole-remote.xml
+++ b/src/test/resources/test-webconsole-remote.xml
@@ -18,6 +18,11 @@
   -->
 
 <configuration>
+  <newRule pattern="*/configuration/osgi"
+           actionClass="org.apache.sling.commons.log.logback.OsgiAction"/>
+  <newRule pattern="*/configuration/appender-ref-osgi"
+           
actionClass="org.apache.sling.commons.log.logback.OsgiAppenderRefAction"/>
+  <osgi/>
   <appender name="CONSOLE" class="ch.qos.logback.core.ConsoleAppender">
     <encoder>
       <pattern>%d{dd.MM.yyyy HH:mm:ss.SSS} *%level* [%thread] %logger 
%message%n</pattern>

-- 
To stop receiving notification emails like this one, please contact
"[email protected]" <[email protected]>.

Reply via email to