Clean up and refactoring in @BeforeClass methods