2018-01-23 17:15:42 +01:00
|
|
|
FactoryBot.define do
|
2017-06-08 14:16:48 +02:00
|
|
|
factory :attestation_template do
|
2018-09-04 16:46:48 +02:00
|
|
|
title { 'title' }
|
|
|
|
body { 'body' }
|
|
|
|
footer { 'footer' }
|
|
|
|
activated { true }
|
2022-11-09 12:09:24 +01:00
|
|
|
association :procedure
|
2017-06-08 14:16:48 +02:00
|
|
|
end
|
2019-08-27 17:42:52 +02:00
|
|
|
|
|
|
|
trait :with_files do
|
2020-06-30 17:53:54 +02:00
|
|
|
logo { Rack::Test::UploadedFile.new('spec/fixtures/files/logo_test_procedure.png', 'image/png') }
|
|
|
|
signature { Rack::Test::UploadedFile.new('spec/fixtures/files/logo_test_procedure.png', 'image/png') }
|
2019-08-27 17:42:52 +02:00
|
|
|
end
|
2020-03-11 16:57:29 +01:00
|
|
|
|
|
|
|
trait :with_gif_files do
|
|
|
|
logo { Rack::Test::UploadedFile.new('./spec/fixtures/files/french-flag.gif', 'image/gif') }
|
|
|
|
signature { Rack::Test::UploadedFile.new('./spec/fixtures/files/beta-gouv.gif', 'image/gif') }
|
|
|
|
end
|
2017-06-08 14:16:48 +02:00
|
|
|
end
|