Remove previous landing page (#19300)
This commit is contained in:
parent
5fd46dddd7
commit
58d5b28cb0
10 changed files with 8 additions and 210 deletions
|
@ -10,30 +10,30 @@ describe 'Localization' do
|
|||
it 'uses a specific region when provided' do
|
||||
headers = { 'Accept-Language' => 'zh-HK' }
|
||||
|
||||
get "/about", headers: headers
|
||||
get "/auth/sign_in", headers: headers
|
||||
|
||||
expect(response.body).to include(
|
||||
I18n.t('about.tagline', locale: 'zh-HK')
|
||||
I18n.t('auth.login', locale: 'zh-HK')
|
||||
)
|
||||
end
|
||||
|
||||
it 'falls back to a locale when region missing' do
|
||||
headers = { 'Accept-Language' => 'es-FAKE' }
|
||||
|
||||
get "/about", headers: headers
|
||||
get "/auth/sign_in", headers: headers
|
||||
|
||||
expect(response.body).to include(
|
||||
I18n.t('about.tagline', locale: 'es')
|
||||
I18n.t('auth.login', locale: 'es')
|
||||
)
|
||||
end
|
||||
|
||||
it 'falls back to english when locale is missing' do
|
||||
headers = { 'Accept-Language' => '12-FAKE' }
|
||||
|
||||
get "/about", headers: headers
|
||||
get "/auth/sign_in", headers: headers
|
||||
|
||||
expect(response.body).to include(
|
||||
I18n.t('about.tagline', locale: 'en')
|
||||
I18n.t('auth.login', locale: 'en')
|
||||
)
|
||||
end
|
||||
end
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue