made rspec generation code more palatable