Sha256: 09a4680710dd1419d167c9be051d5595280e9ab201be28128006c05224eb7b6d

Contents?: true

Size: 1.21 KB

Versions: 3

Compression:

Stored size: 1.21 KB

Contents

require 'openssl'
require 'parallel_report_portal/after_launch'
require "parallel_report_portal/clock"
require "parallel_report_portal/configuration"
require "parallel_report_portal/file_utils"
require "parallel_report_portal/http"
require "parallel_report_portal/version"
require 'parallel_tests'

module ParallelReportPortal
  class Error < StandardError; end

  extend ParallelReportPortal::AfterLaunch
  extend ParallelReportPortal::HTTP
  extend ParallelReportPortal::FileUtils
  extend ParallelReportPortal::Clock

  # Returns the configuration object, initializing it if necessary.
  #
  # @return [Configuration] the configuration object
  def self.configuration
    @configuration ||= Configuration.new
  end

  # Configures the Report Portal environment.
  #
  # @yieldparam [Configuration] config the configuration object yielded to the block
  def self.configure(&block)
    yield configuration
  end

  at_exit do
    if ParallelReportPortal.parallel?
      if ParallelTests.first_process?
        ParallelTests.wait_for_other_processes_to_finish
        delete_file(launch_id_file)
        delete_file(hierarchy_file)
      end
    else
      delete_file(launch_id_file)
      delete_file(hierarchy_file)
    end
  end
end

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
parallel_report_portal-3.0.1 lib/parallel_report_portal.rb
parallel_report_portal-3.0.0 lib/parallel_report_portal.rb
parallel_report_portal-2.5.1 lib/parallel_report_portal.rb