Sha256: 1f7904ca8bf3a71ff0ea2bd3d01f09e704f617726709aa63999310d22b5960a0

Contents?: true

Size: 345 Bytes

Versions: 6

Compression:

Stored size: 345 Bytes

Contents

# rubocop:todo all
require 'singleton'

class SpecConfig
  include Singleton

  COMPACTION_CHANCE = 0.001

  def active_support?
    %w(1 true yes).include?(ENV['WITH_ACTIVE_SUPPORT']) ||
      ENV['WITH_ACTIVE_SUPPORT'] =~ /[0-9]/ && ENV['WITH_ACTIVE_SUPPORT'] != '0'
  end

  def compact?
    %w(1 true yes).include?(ENV['COMPACT'])
  end
end

Version data entries

6 entries across 6 versions & 1 rubygems

Version Path
bson-5.0.2 spec/support/spec_config.rb
bson-5.0.2-java spec/support/spec_config.rb
bson-5.0.1 spec/support/spec_config.rb
bson-5.0.1-java spec/support/spec_config.rb
bson-5.0.0-java spec/support/spec_config.rb
bson-5.0.0 spec/support/spec_config.rb