Refactor dependencyManagement
to enable includes, added it for this
This commit is contained in:
parent
a5cc2611a6
commit
ceddc89fe4
25 changed files with 526 additions and 9 deletions
12
src/it/logback-xml-custom/pom.xml
Normal file
12
src/it/logback-xml-custom/pom.xml
Normal file
|
@ -0,0 +1,12 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 https://maven.apache.org/xsd/maven-4.0.0.xsd">
|
||||
<modelVersion>4.0.0</modelVersion>
|
||||
|
||||
<parent>
|
||||
<groupId>@project.groupId@</groupId>
|
||||
<artifactId>@project.artifactId@-it</artifactId>
|
||||
<version>LOCAL-SNAPSHOT</version>
|
||||
</parent>
|
||||
|
||||
<artifactId>@project.artifactId@-it-log-text</artifactId>
|
||||
</project>
|
21
src/it/logback-xml-custom/postbuild.bsh
Normal file
21
src/it/logback-xml-custom/postbuild.bsh
Normal file
|
@ -0,0 +1,21 @@
|
|||
// verify log
|
||||
|
||||
String expected = "^TRACE io.kokuwa.micronaut.logging.LoggingTest test-output-marker$";
|
||||
String[] logs = org.codehaus.plexus.util.FileUtils.fileRead(basedir + "/build.log").split("\n");
|
||||
|
||||
for (String log : logs) {
|
||||
if (!log.contains("test-output-marker")) {
|
||||
continue;
|
||||
}
|
||||
if (java.util.regex.Pattern.matches(expected, log)) {
|
||||
return true;
|
||||
} else {
|
||||
System.out.println("marker found, but formatting invalid:");
|
||||
System.out.println("[EXPECTED] " + expected);
|
||||
System.out.println("[ACTUAL] " + log);
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
System.out.println("marker not found");
|
||||
return false;
|
13
src/it/logback-xml-custom/src/test/resources/logback.xml
Normal file
13
src/it/logback-xml-custom/src/test/resources/logback.xml
Normal file
|
@ -0,0 +1,13 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<configuration>
|
||||
<appender name="STDOUT" class="ch.qos.logback.core.ConsoleAppender">
|
||||
<encoder>
|
||||
<pattern>%-5level %logger{40} %msg%n</pattern>
|
||||
</encoder>
|
||||
</appender>
|
||||
<logger name="io.kokuwa.micronaut.logging" level="TRACE" />
|
||||
<root level="WARN">
|
||||
<appender-ref ref="STDOUT" />
|
||||
</root>
|
||||
</configuration>
|
||||
|
Loading…
Add table
Add a link
Reference in a new issue