Refactor specs. Add task helpers