summaryrefslogtreecommitdiffstats
path: root/org.eclipse.jgit.test
diff options
context:
space:
mode:
authorMatthias Sohn <matthias.sohn@sap.com>2019-08-10 00:51:30 +0200
committerMatthias Sohn <matthias.sohn@sap.com>2019-08-10 01:21:18 +0200
commit06fc6c7cc0219b3ec515eae70eb3858e29f6d485 (patch)
tree5f462c9f176791ac6997ff9c65006bea8e59783a /org.eclipse.jgit.test
parent42000a71e3b73639f8ba2858f8ba8e7941a1ab1c (diff)
downloadjgit-06fc6c7cc0219b3ec515eae70eb3858e29f6d485.tar.gz
jgit-06fc6c7cc0219b3ec515eae70eb3858e29f6d485.zip
Bazel: enable logging for tests in org.eclipse.jgit.test
- use slf4j-simple for logging in test runs - for log configuration see https://www.slf4j.org/api/org/slf4j/impl/SimpleLogger.html Change-Id: I9f0a532644b31162c867cd0d63f083296eaf6be5 Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
Diffstat (limited to 'org.eclipse.jgit.test')
-rw-r--r--org.eclipse.jgit.test/BUILD1
-rw-r--r--org.eclipse.jgit.test/tst-rsrc/log4j.properties6
-rw-r--r--org.eclipse.jgit.test/tst-rsrc/simplelogger.properties9
3 files changed, 13 insertions, 3 deletions
diff --git a/org.eclipse.jgit.test/BUILD b/org.eclipse.jgit.test/BUILD
index b06778eed0..89bc90f384 100644
--- a/org.eclipse.jgit.test/BUILD
+++ b/org.eclipse.jgit.test/BUILD
@@ -42,6 +42,7 @@ java_library(
resources = DATA,
deps = [
"//lib:junit",
+ "//lib:slf4j-simple",
"//org.eclipse.jgit:jgit",
"//org.eclipse.jgit.junit:junit",
],
diff --git a/org.eclipse.jgit.test/tst-rsrc/log4j.properties b/org.eclipse.jgit.test/tst-rsrc/log4j.properties
index ee1ac35158..fad5933271 100644
--- a/org.eclipse.jgit.test/tst-rsrc/log4j.properties
+++ b/org.eclipse.jgit.test/tst-rsrc/log4j.properties
@@ -7,8 +7,8 @@ log4j.appender.stdout=org.apache.log4j.ConsoleAppender
log4j.appender.stdout.Target=System.out
log4j.appender.stdout.layout=org.apache.log4j.PatternLayout
log4j.appender.stdout.layout.ConversionPattern=%d{yyyy-MM-dd HH:mm:ss} %-5p %c{1}:%L - %m%n
-#log4j.appender.fileLogger.bufferedIO = true
-#log4j.appender.fileLogger.bufferSize = 4096
+log4j.appender.fileLogger.bufferedIO = true
+log4j.appender.fileLogger.bufferSize = 4096
-#log4j.logger.org.eclipse.jgit.util.FS = DEBUG
+log4j.logger.org.eclipse.jgit.util.FS = DEBUG
#log4j.logger.org.eclipse.jgit.internal.storage.file.FileSnapshot = DEBUG
diff --git a/org.eclipse.jgit.test/tst-rsrc/simplelogger.properties b/org.eclipse.jgit.test/tst-rsrc/simplelogger.properties
new file mode 100644
index 0000000000..011b2f8bb0
--- /dev/null
+++ b/org.eclipse.jgit.test/tst-rsrc/simplelogger.properties
@@ -0,0 +1,9 @@
+org.slf4j.simpleLogger.logFile = System.err
+org.slf4j.simpleLogger.cacheOutputStream = true
+org.slf4j.simpleLogger.defaultLogLevel = info
+org.slf4j.simpleLogger.showDateTime = true
+org.slf4j.simpleLogger.dateTimeFormat = HH:mm:ss.SSSXXX
+org.slf4j.simpleLogger.showThreadName = true
+
+#org.slf4j.simpleLogger.log.org.eclipse.jgit.util.FS = debug
+#org.slf4j.simpleLogger.log.org.eclipse.jgit.internal.storage.file.FileSnapshot = debug