Sha256: c1a40159b6e6904c164513cd7e244a5f4c89f99bdaa64e8a35afb35b6d526af8
Contents?: true
Size: 668 Bytes
Versions: 7
Compression:
Stored size: 668 Bytes
Contents
FactoryBot.define do factory :salt_module, :class => 'ForemanSalt::SaltModule' do sequence(:name) { |n| "module#{n}" } end factory :salt_environment, :class => 'ForemanSalt::SaltEnvironment' do sequence(:name) { |n| "environment#{n}" } end end FactoryBot.modify do factory :hostgroup do trait :with_salt_modules do salt_environment { FactoryBot.build :salt_environment } salt_modules { FactoryBot.create_list :salt_module, 10, :salt_environments => [self.salt_environment] } end end factory :smart_proxy do trait :with_salt_feature do features { [::Feature.find_or_create_by(:name => 'Salt')] } end end end
Version data entries
7 entries across 7 versions & 1 rubygems