Added fix for JUnit tests