Visitor tests and refactorings #8