This feels like a very silly question. But how do I unit test methods of a class that contains a final static logger
? I don't need or necessarily want it to log anything at all, yet when I run my unit test that should pass I get
[Fatal Error] log4j2.xml:1:151: Premature end of file.
ERROR StatusLogger Error parsing C:\...\MyProject\target\classes\log4j2.xml
Am I to mock it, ignore or what? I don't want it to log for tests but I obviously need it to log when it the app itself is executing.
Aucun commentaire:
Enregistrer un commentaire