Refactoring and adding Arquillian for tests