Set locales in test environment to avoid failed specs

This commit is contained in:
Pierre Mesure
2019-05-24 22:24:10 +02:00
parent 1f0a4cd875
commit d317af572c

View File

@@ -1,6 +1,18 @@
Rails.application.configure do Rails.application.configure do
# Settings specified here will take precedence over those in config/application.rb. # Settings specified here will take precedence over those in config/application.rb.
# Some tests require the following languages (en, es, fr, nl, pt-BR)
# so we override the available languages for the test environment.
config.i18n.default_locale = :en
available_locales = [
"en",
"es",
"fr",
"nl",
"pt-BR"
]
config.i18n.available_locales = available_locales
# The test environment is used exclusively to run your application's # The test environment is used exclusively to run your application's
# test suite. You never need to work with it otherwise. Remember that # test suite. You never need to work with it otherwise. Remember that
# your test database is "scratch space" for the test suite and is wiped # your test database is "scratch space" for the test suite and is wiped