I am using Factory Girl to create two instances in my model/unit test for a Group. I am testing the model to check that a call to .current returns only the \'current\' groups ac
It's a bad idea to skip validations by default in factory. Some hair will be pulled out finding that.
The nicest way, I think:
trait :skip_validate do to_create {|instance| instance.save(validate: false)} end
Then in your test:
create(:group, :skip_validate, expiry: Time.now + 1.week)