What I learned while digging into FactoryGirl’s build_stubbed

Spoiler Alert: I found build_stubbed not viable as a replacement of create​in our test suite. To remove the dependency of the database in tests, I would recommend RSpec’s instance_double instead. Read on to find out why. I was excited to find out that FactoryGirl has methods to create in-memory objects instead of hitting the database. Running a … More What I learned while digging into FactoryGirl’s build_stubbed