-
-
Notifications
You must be signed in to change notification settings - Fork 281
Open
Labels
Description
A common mistake I see is using closure variables instead of let statements. An example of this:
describe User do
user = FactoryBot.create(:user)
it "exists" do
expect(user).not_to be_nil
end
end
The issue with above example is now a user exists in the DB for the rest of the tests since it is not part of example transaction.
I'd be willing to work on a PR for this if you think this would be a good addition to this gem.
pirj, ydakuka and iovis