spec/audited_spec_helpers.rb in audited-5.4.2 vs spec/audited_spec_helpers.rb in audited-5.4.3
- old
+ new
@@ -1,9 +1,13 @@
module AuditedSpecHelpers
def create_user(attrs = {})
Models::ActiveRecord::User.create({name: "Brandon", username: "brandon", password: "password", favourite_device: "Android Phone"}.merge(attrs))
end
+ def create_user_with_readonly_attrs(attrs = {})
+ Models::ActiveRecord::UserWithReadOnlyAttrs.create({name: "Brandon", username: "brandon", password: "password", favourite_device: "Android Phone"}.merge(attrs))
+ end
+
def build_user(attrs = {})
Models::ActiveRecord::User.new({name: "darth", username: "darth", password: "noooooooo"}.merge(attrs))
end
def create_versions(n = 2, attrs = {})