refactoring visitor and irrelevenat tests