Sha256: 905e70491de23418759ff890272d802a9054eaf1694f7b33ed99c6eb8772915d
Contents?: true
Size: 472 Bytes
Versions: 6
Compression:
Stored size: 472 Bytes
Contents
class ActiveSupport::TestCase # # Helpers for creating new users # def unique_identity @@unique_identity_count ||= 0 @@unique_identity_count += 1 "user-#{@@unique_identity_count}@mail.invalid" end def valid_attributes(attributes = {}) {email: unique_identity, password: "12345678", password_confirmation: "12345678"}.update(attributes) end def new_user(attributes = {}) User.new(valid_attributes(attributes)).save end end
Version data entries
6 entries across 6 versions & 1 rubygems