Sha256: 14a9c32ed076aefd09983dd8efaac61ddb29a4d24d4cc9b766c7d01b48f9f139

Contents?: true

Size: 425 Bytes

Versions: 109

Compression:

Stored size: 425 Bytes

Contents

# frozen_string_literal: true

FactoryBot.define do
  factory :alchemy_dummy_user, class: "DummyUser" do
    sequence(:email) { |n| "john.#{n}@doe.com" }
    password { "s3cr3t" }
    alchemy_roles { ["member"] }

    trait :as_admin do
      alchemy_roles { ["admin"] }
    end

    trait :as_author do
      alchemy_roles { ["author"] }
    end

    trait :as_editor do
      alchemy_roles { ["editor"] }
    end
  end
end

Version data entries

109 entries across 109 versions & 1 rubygems

Version Path
alchemy_cms-7.3.5 lib/alchemy/test_support/factories/dummy_user_factory.rb
alchemy_cms-7.2.8 lib/alchemy/test_support/factories/dummy_user_factory.rb
alchemy_cms-7.1.13 lib/alchemy/test_support/factories/dummy_user_factory.rb
alchemy_cms-7.0.16 lib/alchemy/test_support/factories/dummy_user_factory.rb
alchemy_cms-7.3.4 lib/alchemy/test_support/factories/dummy_user_factory.rb
alchemy_cms-7.3.3 lib/alchemy/test_support/factories/dummy_user_factory.rb
alchemy_cms-7.3.2 lib/alchemy/test_support/factories/dummy_user_factory.rb
alchemy_cms-7.2.7 lib/alchemy/test_support/factories/dummy_user_factory.rb
alchemy_cms-7.3.1 lib/alchemy/test_support/factories/dummy_user_factory.rb
alchemy_cms-7.3.0 lib/alchemy/test_support/factories/dummy_user_factory.rb
alchemy_cms-7.2.6 lib/alchemy/test_support/factories/dummy_user_factory.rb
alchemy_cms-7.2.5 lib/alchemy/test_support/factories/dummy_user_factory.rb
alchemy_cms-7.1.12 lib/alchemy/test_support/factories/dummy_user_factory.rb
alchemy_cms-7.0.15 lib/alchemy/test_support/factories/dummy_user_factory.rb
alchemy_cms-6.1.10 lib/alchemy/test_support/factories/dummy_user_factory.rb
alchemy_cms-7.2.4 lib/alchemy/test_support/factories/dummy_user_factory.rb
alchemy_cms-7.1.11 lib/alchemy/test_support/factories/dummy_user_factory.rb
alchemy_cms-7.2.3 lib/alchemy/test_support/factories/dummy_user_factory.rb
alchemy_cms-7.1.10 lib/alchemy/test_support/factories/dummy_user_factory.rb
alchemy_cms-7.2.2 lib/alchemy/test_support/factories/dummy_user_factory.rb