Issue #14438 has been updated by naruse (Yui NARUSE).

Backport changed from 2.3: REQUIRED, 2.4: REQUIRED, 2.5: REQUIRED to 2.3: REQUIRED, 2.4: REQUIRED, 2.5: DONE

ruby_2_5 r62609 merged revision(s) 62506,62508.

----------------------------------------
Bug #14438: TestTimeTZ: failures with recent version of tzdata
https://bugs.ruby-lang.org/issues/14438#change-70716

* Author: terceiro (Antonio Terceiro)
* Status: Closed
* Priority: Normal
* Assignee: 
* Target version: 
* ruby -v: ruby 2.6.0dev (2018-02-04 master 62196) [x86_64-linux]
* Backport: 2.3: REQUIRED, 2.4: REQUIRED, 2.5: DONE
----------------------------------------
This has beeen reported in [Debian as Debian bug #889046](https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=889046)

Recent tzdata has fixed some definitions about the Japan timezone in the 50s:


> http://mm.icann.org/pipermail/tz-announce/2018-January/000048.html
> 
> Changes to past time stamps
> 
> Japanese DST transitions (1948-1951) were Sundays at 00:00, not
> Saturdays or Sundays at 02:00.  (Thanks to Takayuki Nikai.)

With this update, existing Ruby tests fail:

~~~
$ make test-all TESTS=test/ruby/test_time_tz.rb 
Run options: "--ruby=./miniruby -I./lib -I. -I.ext/common  ./tool/runruby.rb --extout=.ext  -- --disable-gems" --excludes-dir=./test/excludes --name=!/memory_leak/

# Running tests:

[  4/108] TestTimeTZ#test_asia_tokyo = 0.00 s         
  1) Failure:
TestTimeTZ#test_asia_tokyo [/home/terceiro/src/ruby/test/ruby/test_time_tz.rb:129]:
TZ=Asia/Tokyo Time.local(1951, 5, 6, 2, 0, 0).
<"1951-05-06 03:00:00 +1000"> expected but was
<"1951-05-06 02:00:00 +1000">.

[ 62/108] TestTimeTZ#test_gen_Asia_Tokyo_24 = 0.00 s         
  2) Failure:
TestTimeTZ#test_gen_Asia_Tokyo_24 [/home/terceiro/src/ruby/test/ruby/test_time_tz.rb:259]:
TZ=Asia/Tokyo Time.utc(1951, 5, 5, 16, 59, 59).localtime.
<"1951-05-06 01:59:59 +0900"> expected but was
<"1951-05-06 02:59:59 +1000">.

[ 65/108] TestTimeTZ#test_gen_Asia_Tokyo_27 = 0.00 s
  3) Failure:
TestTimeTZ#test_gen_Asia_Tokyo_27 [/home/terceiro/src/ruby/test/ruby/test_time_tz.rb:259]:
TZ=Asia/Tokyo Time.utc(1951, 9, 7, 16, 0, 0).localtime.
<"1951-09-08 01:00:00 +0900"> expected but was
<"1951-09-08 02:00:00 +1000">.

[ 66/108] TestTimeTZ#test_gen_Asia_Tokyo_69 = 0.00 s
  4) Failure:
TestTimeTZ#test_gen_Asia_Tokyo_69 [/home/terceiro/src/ruby/test/ruby/test_time_tz.rb:277]:
TZ=Asia/Tokyo Time.local(1951, 5, 6, 1, 59, 59).
<"1951-05-06 01:59:59 +0900"> expected but was
<"1951-05-06 01:59:59 +1000">.

[ 69/108] TestTimeTZ#test_gen_Asia_Tokyo_72 = 0.00 s
  5) Failure:
TestTimeTZ#test_gen_Asia_Tokyo_72 [/home/terceiro/src/ruby/test/ruby/test_time_tz.rb:295]:
TZ=Asia/Tokyo Time.local(0, 0, 1, 8, 9, 1951, nil, nil, false, nil).
<"1951-09-08 01:00:00 +0900"> expected but was
<"1951-09-08 01:00:00 +1000">.

Finished tests in 0.028324s, 3813.0025 tests/s, 35164.3559 assertions/s.
108 tests, 996 assertions, 5 failures, 0 errors, 0 skips

ruby -v: ruby 2.6.0dev (2018-02-04 master 62196) [x86_64-linux]
uncommon.mk:699: recipe for target 'yes-test-all' failed
make: *** [yes-test-all] Error 5
~~~





-- 
https://bugs.ruby-lang.org/

Unsubscribe: <mailto:ruby-core-request / ruby-lang.org?subject=unsubscribe>
<http://lists.ruby-lang.org/cgi-bin/mailman/options/ruby-core>