more specs and some refactoring