added tests and refactored a few things
added tests and refactored a few things
Merge pull request #5 from fishplate/rspec_tests_refactor

added tests and refactored a few things