Sha256: 200b753a57ce7432d84547289d51867c3f8eb67aac1dcb9dc03047d4b9cdade4

Contents?: true

Size: 578 Bytes

Versions: 9

Compression:

Stored size: 578 Bytes

Contents

# frozen_string_literal: true

require_relative '../application'

# ExportManager#run
module ExportManager
  def self.run(main_report, cases, args)
    # default :mode=>:all, :format=>:txt
    format = args[:format] || Application.instance.default[:format]
    mode = args[:mode] || :all
    # Export case reports
    if %i[details all].include? mode
      threads = []
      cases.each { |c| threads << Thread.new { c.export format } }
      threads.each(&:join)
    end
    # Export resume report
    main_report.export_resume format if %i[resume all].include? mode
  end
end

Version data entries

9 entries across 9 versions & 1 rubygems

Version Path
teuton-2.1.7 lib/teuton/case_manager/export_manager.rb
teuton-2.1.6 lib/teuton/case_manager/export_manager.rb
teuton-2.1.5dev lib/teuton/case_manager/export_manager.rb
teuton-2.1.4 lib/teuton/case_manager/export_manager.rb
teuton-2.1.3 lib/teuton/case_manager/export_manager.rb
teuton-2.1.2 lib/teuton/case_manager/export_manager.rb
teuton-2.1.1 lib/teuton/case_manager/export_manager.rb
teuton-2.1.0 lib/teuton/case_manager/export_manager.rb
teuton-0.0.1 lib/teuton/case_manager/export_manager.rb