diff options
Diffstat (limited to 'spec/factories/bulk_import/export_batches.rb')
-rw-r--r-- | spec/factories/bulk_import/export_batches.rb | 24 |
1 files changed, 24 insertions, 0 deletions
diff --git a/spec/factories/bulk_import/export_batches.rb b/spec/factories/bulk_import/export_batches.rb new file mode 100644 index 00000000000..f5f12696f5f --- /dev/null +++ b/spec/factories/bulk_import/export_batches.rb @@ -0,0 +1,24 @@ +# frozen_string_literal: true + +FactoryBot.define do + factory :bulk_import_export_batch, class: 'BulkImports::ExportBatch' do + association :export, factory: :bulk_import_export + + upload { association(:bulk_import_export_upload) } + + status { 0 } + batch_number { 1 } + + trait :started do + status { 0 } + end + + trait :finished do + status { 1 } + end + + trait :failed do + status { -1 } + end + end +end |