Refine rspec tests