Sha256: a6d9f59d7ce7267b39402541e34eef6e4d2a064da0e481fcd137f4e2d1f7bda4

Contents?: true

Size: 601 Bytes

Versions: 33

Compression:

Stored size: 601 Bytes

Contents

require 'test_helper'

class I18nGettextPluralKeysTest < I18n::TestCase
  def setup
    super
    I18n::Gettext.plural_keys[:zz] = [:value1, :value2]
  end

  test "Returns the plural keys of the given locale if present" do
    assert_equal I18n::Gettext.plural_keys(:zz), [:value1, :value2]
  end

  test "Returns the plural keys of :en if given locale not present" do
    assert_equal I18n::Gettext.plural_keys(:yy), [:one, :other]
  end

  test "Returns the whole hash with no arguments" do
    assert_equal I18n::Gettext.plural_keys, { :en => [:one, :other], :zz => [:value1, :value2] }
  end
end

Version data entries

33 entries across 31 versions & 8 rubygems

Version Path
mumukit-content-type-1.12.1 vendor/bundle/ruby/2.7.0/gems/i18n-0.9.5/test/i18n/gettext_plural_keys_test.rb
mumukit-content-type-1.12.0 vendor/bundle/ruby/2.7.0/gems/i18n-0.9.5/test/i18n/gettext_plural_keys_test.rb
mumukit-content-type-1.11.1 vendor/bundle/ruby/2.6.0/gems/i18n-0.9.5/test/i18n/gettext_plural_keys_test.rb
files.com-1.0.55 docs/vendor/bundle/ruby/2.5.0/gems/i18n-0.9.5/test/i18n/gettext_plural_keys_test.rb
vagrant-unbundled-2.2.7.0 vendor/bundle/ruby/2.6.0/gems/i18n-1.1.1/test/i18n/gettext_plural_keys_test.rb
vagrant-unbundled-2.2.6.2 vendor/bundle/ruby/2.6.0/gems/i18n-1.1.1/test/i18n/gettext_plural_keys_test.rb
vagrant-unbundled-2.2.6.1 vendor/bundle/ruby/2.6.0/gems/i18n-1.1.1/test/i18n/gettext_plural_keys_test.rb
vagrant-unbundled-2.2.6.0 vendor/bundle/ruby/2.6.0/gems/i18n-1.1.1/test/i18n/gettext_plural_keys_test.rb
vagrant-unbundled-2.2.5.0 vendor/bundle/ruby/2.6.0/gems/i18n-1.1.1/test/i18n/gettext_plural_keys_test.rb
vagrant-unbundled-2.2.5.0 vendor/bundle/ruby/2.5.0/gems/i18n-1.1.1/test/i18n/gettext_plural_keys_test.rb
cocoapods-dependency-html-0.0.2 vendor/bundle/gems/i18n-0.9.5/test/i18n/gettext_plural_keys_test.rb
cocoapods-dependency-html-0.0.1 vendor/bundle/gems/i18n-0.9.5/test/i18n/gettext_plural_keys_test.rb
vagrant-unbundled-2.2.4.0 vendor/bundle/ruby/2.6.0/gems/i18n-1.1.1/test/i18n/gettext_plural_keys_test.rb
vagrant-unbundled-2.2.4.0 vendor/bundle/ruby/2.5.0/gems/i18n-1.1.1/test/i18n/gettext_plural_keys_test.rb
vagrant-unbundled-2.2.3.0 vendor/bundle/ruby/2.5.0/gems/i18n-1.1.1/test/i18n/gettext_plural_keys_test.rb
vagrant-unbundled-2.2.2.0 vendor/bundle/ruby/2.5.0/gems/i18n-1.1.1/test/i18n/gettext_plural_keys_test.rb
i18n-1.1.1 test/i18n/gettext_plural_keys_test.rb
i18n-1.1.0 test/i18n/gettext_plural_keys_test.rb
monero_wallet_gen-0.1.0 vendor/bundle/ruby/2.3.0/gems/i18n-1.0.1/test/i18n/gettext_plural_keys_test.rb
i18n-1.0.1 test/i18n/gettext_plural_keys_test.rb