logo

mastofe

My custom branche(s) on git.pleroma.social/pleroma/mastofe git clone https://hacktivis.me/git/mastofe.git

settings_helper_spec.rb (567B)


  1. # frozen_string_literal: true
  2. require 'rails_helper'
  3. describe SettingsHelper do
  4. describe 'the HUMAN_LOCALES constant' do
  5. it 'includes all I18n locales' do
  6. options = I18n.available_locales
  7. expect(described_class::HUMAN_LOCALES.keys).to include(*options)
  8. end
  9. end
  10. describe 'human_locale' do
  11. it 'finds the human readable local description from a key' do
  12. # Ensure the value is as we expect
  13. expect(described_class::HUMAN_LOCALES[:en]).to eq('English')
  14. expect(helper.human_locale(:en)).to eq('English')
  15. end
  16. end
  17. end