Win a copy of Re-engineering Legacy Software this week in the Refactoring forum
or Docker in Action in the Cloud/Virtualization forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

turn logging off for junit during build

 
Mark Lybarger
Ranch Hand
Posts: 72
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
i have junit tests for some classes that run during our build. these classes under test use log4j (through commons-logging actually). i'd like to turn logging off only for running the junit testing. does anyone have idea/example how to do this?
 
Paul Sturrock
Bartender
Posts: 10336
Eclipse IDE Hibernate Java
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Set the logging threshold for those classes in log4j.properties.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic