Sha256: c43808e4da64d0abf1ee52351d909a50f59d222420c852acebb82b639bb3719e
Contents?: true
Size: 552 Bytes
Versions: 12
Compression:
Stored size: 552 Bytes
Contents
# frozen_string_literal: true describe Spotlight::CustomTranslationExtension do let(:exhibit) { FactoryBot.create(:exhibit) } subject do Class.new(ActiveRecord::Base) do include Spotlight::CustomTranslationExtension end end describe '.current_exhibit' do it 'sets the current exhibit' do subject.current_exhibit = exhibit expect(subject.current_exhibit).to eq exhibit end it 'reloads the i18n' do allow(I18n.backend).to receive(:reload!) subject.current_exhibit = exhibit end end end
Version data entries
12 entries across 12 versions & 1 rubygems