Sha256: f126cffbd1e7f1484f1db4ebed0b00629421687288973f0827377cb45fbad9af

Contents?: true

Size: 505 Bytes

Versions: 29

Compression:

Stored size: 505 Bytes

Contents

require "spec_helper"

RSpec.describe Relaton::Config do
  before { restore_to_default_config }
  after { restore_to_default_config }

  describe ".configure" do
    it "allows user to set custom configuration" do
      log_types = ["info", :warning, :error]

      Relaton.configure do |config|
        config.logs = log_types
      end

      expect(Relaton.configuration.logs).to eq(log_types)
    end
  end

  def restore_to_default_config
    Relaton.configuration.logs = %i(warning error)
  end
end

Version data entries

29 entries across 29 versions & 2 rubygems

Version Path
relaton-1.7.pre7 spec/relaton/config_spec.rb
relaton-1.7.6 spec/relaton/config_spec.rb
relaton-1.7.5 spec/relaton/config_spec.rb
relaton-1.7.4 spec/relaton/config_spec.rb
relaton-1.7.3 spec/relaton/config_spec.rb
relaton-1.7.2 spec/relaton/config_spec.rb
relaton-1.7.1 spec/relaton/config_spec.rb
relaton-1.7.0 spec/relaton/config_spec.rb
relaton-1.6.0 spec/relaton/config_spec.rb
relaton-1.6.pre1 spec/relaton/config_spec.rb
relaton-1.5.0 spec/relaton/config_spec.rb
relaton-1.5.pre spec/relaton/config_spec.rb
relaton-1.4.1 spec/relaton/config_spec.rb
relaton-1.4.0 spec/relaton/config_spec.rb
relaton-1.3.0 spec/relaton/config_spec.rb
metanorma-cli-1.3.4 gems/ruby/2.6.0/gems/relaton-1.2.0/spec/relaton/config_spec.rb
metanorma-cli-1.3.3.1 gems/ruby/2.6.0/gems/relaton-1.2.0/spec/relaton/config_spec.rb
relaton-1.2.0 spec/relaton/config_spec.rb
relaton-1.1.0 spec/relaton/config_spec.rb
relaton-1.0.3 spec/relaton/config_spec.rb