Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'spec/lib/gitlab/i18n_spec.rb')
-rw-r--r--spec/lib/gitlab/i18n_spec.rb8
1 files changed, 8 insertions, 0 deletions
diff --git a/spec/lib/gitlab/i18n_spec.rb b/spec/lib/gitlab/i18n_spec.rb
index 592adadc362..ee10739195a 100644
--- a/spec/lib/gitlab/i18n_spec.rb
+++ b/spec/lib/gitlab/i18n_spec.rb
@@ -5,6 +5,14 @@ require 'spec_helper'
RSpec.describe Gitlab::I18n do
let(:user) { create(:user, preferred_language: 'es') }
+ describe '.selectable_locales' do
+ it 'does not return languages that should not be available in the UI' do
+ Gitlab::I18n::NOT_AVAILABLE_IN_UI.each do |language|
+ expect(described_class.selectable_locales).not_to include(language)
+ end
+ end
+ end
+
describe '.locale=' do
after do
described_class.use_default_locale