How to refactor this

Hi, I’ve written some model specs, and some code to make them all pass, but I don’t like the code I’ve written… it’s in desperate need of refactoring. I’ve included the code, as well as the specs to help you understand what I’m trying to do. I’d appreciate any help.

Thanks, -Nathan