Improve spec tests