refactor spec files and add let