refactor todo create spec to abstract out repeated code