Hello community,

here is the log from the commit of package rubygem-i18n for openSUSE:Factory 
checked in at 2018-03-06 10:45:23
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/rubygem-i18n (Old)
 and      /work/SRC/openSUSE:Factory/.rubygem-i18n.new (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Package is "rubygem-i18n"

Tue Mar  6 10:45:23 2018 rev:18 rq:577157 version:1.0.0

Changes:
--------
--- /work/SRC/openSUSE:Factory/rubygem-i18n/rubygem-i18n.changes        
2018-02-12 10:15:37.756609472 +0100
+++ /work/SRC/openSUSE:Factory/.rubygem-i18n.new/rubygem-i18n.changes   
2018-03-06 10:45:26.688279237 +0100
@@ -1,0 +2,6 @@
+Wed Feb 14 05:29:52 UTC 2018 - [email protected]
+
+- updated to version 1.0.0
+  no changelog found
+
+-------------------------------------------------------------------

Old:
----
  i18n-0.9.4.gem

New:
----
  i18n-1.0.0.gem

++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Other differences:
------------------
++++++ rubygem-i18n.spec ++++++
--- /var/tmp/diff_new_pack.ylXMCD/_old  2018-03-06 10:45:27.276257994 +0100
+++ /var/tmp/diff_new_pack.ylXMCD/_new  2018-03-06 10:45:27.280257849 +0100
@@ -24,12 +24,12 @@
 #
 
 Name:           rubygem-i18n
-Version:        0.9.4
+Version:        1.0.0
 Release:        0
 %define mod_name i18n
 %define mod_full_name %{mod_name}-%{version}
 BuildRoot:      %{_tmppath}/%{name}-%{version}-build
-BuildRequires:  %{ruby >= 1.9.3}
+BuildRequires:  %{ruby >= 2.0.0}
 BuildRequires:  %{rubygem gem2rpm}
 BuildRequires:  ruby-macros >= 5
 Url:            http://github.com/svenfuchs/i18n

++++++ i18n-0.9.4.gem -> i18n-1.0.0.gem ++++++
Binary files old/checksums.yaml.gz and new/checksums.yaml.gz differ
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/lib/i18n/backend/simple.rb 
new/lib/i18n/backend/simple.rb
--- old/lib/i18n/backend/simple.rb      2018-02-09 06:19:53.000000000 +0100
+++ new/lib/i18n/backend/simple.rb      2018-02-14 02:29:03.000000000 +0100
@@ -29,7 +29,8 @@
         # translations will be overwritten by new ones only at the deepest
         # level of the hash.
         def store_translations(locale, data, options = {})
-          if I18n.available_locales_initialized? &&
+          if I18n.enforce_available_locales &&
+            I18n.available_locales_initialized? &&
             !I18n.available_locales.include?(locale.to_sym) &&
             !I18n.available_locales.include?(locale.to_s)
             return data
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/lib/i18n/version.rb new/lib/i18n/version.rb
--- old/lib/i18n/version.rb     2018-02-09 06:19:53.000000000 +0100
+++ new/lib/i18n/version.rb     2018-02-14 02:29:04.000000000 +0100
@@ -1,3 +1,3 @@
 module I18n
-  VERSION = "0.9.4"
+  VERSION = "1.0.0"
 end
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/metadata new/metadata
--- old/metadata        2018-02-09 06:19:53.000000000 +0100
+++ new/metadata        2018-02-14 02:29:03.000000000 +0100
@@ -1,7 +1,7 @@
 --- !ruby/object:Gem::Specification
 name: i18n
 version: !ruby/object:Gem::Version
-  version: 0.9.4
+  version: 1.0.0
 platform: ruby
 authors:
 - Sven Fuchs
@@ -13,7 +13,7 @@
 autorequire: 
 bindir: bin
 cert_chain: []
-date: 2018-02-09 00:00:00.000000000 Z
+date: 2018-02-14 00:00:00.000000000 Z
 dependencies:
 - !ruby/object:Gem::Dependency
   name: concurrent-ruby
@@ -143,7 +143,7 @@
   requirements:
   - - ">="
     - !ruby/object:Gem::Version
-      version: 1.9.3
+      version: 2.0.0
 required_rubygems_version: !ruby/object:Gem::Requirement
   requirements:
   - - ">="
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/test/backend/simple_test.rb 
new/test/backend/simple_test.rb
--- old/test/backend/simple_test.rb     2018-02-09 06:19:53.000000000 +0100
+++ new/test/backend/simple_test.rb     2018-02-14 02:29:04.000000000 +0100
@@ -70,12 +70,23 @@
     assert_equal Hash[:'en', {:foo => {:bar => 'bar', :baz => 'baz'}}], 
translations
   end
 
-  test "simple store_translations: do not store translations for locales not 
explicitly marked as available" do
+  test "simple store_translations: do not store translations unavailable 
locales if enforce_available_locales is true" do
+    begin
+      I18n.enforce_available_locales = true
+      I18n.available_locales = [:en, :es]
+      store_translations(:fr, :foo => {:bar => 'barfr', :baz => 'bazfr'})
+      store_translations(:es, :foo => {:bar => 'bares', :baz => 'bazes'})
+      assert_nil translations[:fr]
+      assert_equal Hash[:foo, {:bar => 'bares', :baz => 'bazes'}], 
translations[:es]
+    ensure
+      I18n.config.enforce_available_locales = false
+    end
+  end
+
+  test "simple store_translations: store translations for unavailable locales 
if enforce_available_locales is false" do
     I18n.available_locales = [:en, :es]
     store_translations(:fr, :foo => {:bar => 'barfr', :baz => 'bazfr'})
-    store_translations(:es, :foo => {:bar => 'bares', :baz => 'bazes'})
-    assert_nil translations[:fr]
-    assert_equal Hash[:foo, {:bar => 'bares', :baz => 'bazes'}], 
translations[:es]
+    assert_equal Hash[:foo, {:bar => 'barfr', :baz => 'bazfr'}], 
translations[:fr]
   end
 
   # reloading translations


Reply via email to