Move log4j configuration from main to test.