Kaynağa Gözat

Hold value of I18n.locale with ApplicationHelperSpec (#3474)

master
Yamagishi Kazutoshi 7 yıl önce
committed by Eugen Rochko
ebeveyn
işleme
1a4860a57a
1 değiştirilmiş dosya ile 6 ekleme ve 0 silme
  1. +6
    -0
      spec/helpers/application_helper_spec.rb

+ 6
- 0
spec/helpers/application_helper_spec.rb Dosyayı Görüntüle

@@ -18,6 +18,12 @@ describe ApplicationHelper do
end

describe 'add_rtl_body_class' do
around do |example|
current_locale = I18n.locale
example.run
I18n.locale = current_locale
end

it 'adds rtl body class if locale is Arabic' do
I18n.locale = :ar
expect(helper.add_rtl_body_class('other classes')).to eq 'other classes rtl'


Yükleniyor…
İptal
Kaydet