Sha256: 711c7d8010c739fc6f66da486d06c0232791e57f9220c5f6ecbe8ad21d320ec7

Contents?: true

Size: 387 Bytes

Versions: 4

Compression:

Stored size: 387 Bytes

Contents

# frozen_string_literal: true

require 'rails_helper'

RSpec.describe Rating::Config, '.rate_table' do
  context 'when rating.yml does not exist' do
    it { expect(subject.rate_table).to eq 'rating_rates' }
  end if ENV['CONFIG_ENABLED'] != 'true'

  context 'when rating.yml exists' do
    it { expect(subject.rate_table).to eq 'reviews' }
  end if ENV['CONFIG_ENABLED'] == 'true'
end

Version data entries

4 entries across 4 versions & 1 rubygems

Version Path
rating-0.8.0 spec/config/rate_table_spec.rb
rating-0.7.0 spec/config/rate_table_spec.rb
rating-0.6.0 spec/config/rate_table_spec.rb
rating-0.5.0 spec/config/rate_table_spec.rb