Sha256: 22dfab61af220d4e58a7165173bd0e8e774f76e0de7485d036858a4533e4e6eb

Contents?: true

Size: 651 Bytes

Versions: 4

Compression:

Stored size: 651 Bytes

Contents

module Knapsack
  class Config
    class << self
      def report_path
        ENV['KNAPSACK_REPORT_PATH'] || 'knapsack_report.json'
      end

      def ci_node_total
        ENV['CI_NODE_TOTAL'] || ENV['CIRCLE_NODE_TOTAL'] || 1
      end

      def ci_node_index
        ENV['CI_NODE_INDEX'] || ENV['CIRCLE_NODE_INDEX'] || 0
      end

      def spec_pattern
        ENV['KNAPSACK_SPEC_PATTERN'] || 'spec/**/*_spec.rb'
      end

      def enable_time_offset_warning
        true
      end

      def time_offset_in_seconds
        30
      end

      def generate_report
        ENV['KNAPSACK_GENERATE_REPORT'] || false
      end
    end
  end
end

Version data entries

4 entries across 4 versions & 1 rubygems

Version Path
knapsack-0.2.0 lib/knapsack/config.rb
knapsack-0.1.4 lib/knapsack/config.rb
knapsack-0.1.3 lib/knapsack/config.rb
knapsack-0.1.2 lib/knapsack/config.rb