Skip to content

Commit

Permalink
Update spec to use the store preference
Browse files Browse the repository at this point in the history
  • Loading branch information
alepore committed Mar 27, 2018
1 parent 2434500 commit 546904d
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 5 deletions.
1 change: 1 addition & 0 deletions .bundle/config
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
--- {}
8 changes: 3 additions & 5 deletions spec/features/admin/translations_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -55,15 +55,13 @@
end

context 'solidus_auth_devise pages translation' do
let(:locale) { :it }

background do
SolidusI18n::Config.available_locales = [:en, :it]
store.update_attributes(preferred_available_locales: [:en, :it])
end

scenario 'the login page is translated' do
visit spree.admin_login_path(locale: locale)
expect(page).to have_content(/#{Spree.t(:admin_login, locale: locale)}/i)
visit spree.admin_login_path(locale: "it")
expect(page).to have_content(/#{Spree.t(:admin_login, locale: :it)}/i)
end
end
end

0 comments on commit 546904d

Please sign in to comment.