[ruby-core:96312] [Ruby master Bug#16410] Spec failure - "File.utime allows Time instances in the far future to set mtime and atime"

[email protected]
Newsgroups gmane.comp.lang.ruby.core
Message-ID <redmine.journal-83224.20191218144250.e6b1dff93afe7cd8@ruby-lang.org>
Issue #16410 has been updated by vo.x (Vit Ondruch).


~~~
$ cat /etc/os-release 
NAME=Fedora
VERSION="32 (Rawhide)"
ID=fedora
VERSION_ID=32
VERSION_CODENAME=""
PLATFORM_ID="platform:f32"
PRETTY_NAME="Fedora 32 (Rawhide)"
ANSI_COLOR="0;34"
LOGO=fedora-logo-icon
CPE_NAME="cpe:/o:fedoraproject:fedora:32"
HOME_URL="https://fedoraproject.org/"
DOCUMENTATION_URL="https://docs.fedoraproject.org/en-US/fedora/rawhide/system-administrators-guide/"
SUPPORT_URL="https://fedoraproject.org/wiki/Communicating_and_getting_help"
BUG_REPORT_URL="https://bugzilla.redhat.com/"
REDHAT_BUGZILLA_PRODUCT="Fedora"
REDHAT_BUGZILLA_PRODUCT_VERSION=rawhide
REDHAT_SUPPORT_PRODUCT="Fedora"
REDHAT_SUPPORT_PRODUCT_VERSION=rawhide
PRIVACY_POLICY_URL="https://fedoraproject.org/wiki/Legal:PrivacyPolicy"

$ uname -a
Linux 279feb6400424441b3fc1b2fed5f110b 5.4.0-2.fc32.x86_64 #1 SMP Mon Nov 25 22:45:19 UTC 2019 x86_64 x86_64 x86_64 GNU/Linux

$ rpm -q glibc
glibc-2.30.9000-25.fc32.x86_64
~~~

The system I am using for testing is actually running in systemd-nspawn container on Ext4.

----------------------------------------
Bug #16410: Spec failure - "File.utime allows Time instances in the far future to set mtime and atime"
https://bugs.ruby-lang.org/issues/16410#change-83224

* Author: vo.x (Vit Ondruch)
* Status: Open
* Priority: Normal
* Assignee: 
* Target version: 
* ruby -v: ruby 2.7.0dev (2019-12-09 master c2dc27d643) [x86_64-linux]
* Backport: 2.5: UNKNOWN, 2.6: UNKNOWN
----------------------------------------
I observe the following spec error:

~~~
$ make test-all TESTS="spec/ruby/core/file/utime_spec.rb" MSPECOPT="-fs"
./revision.h unchanged
ruby 2.7.0dev (2019-12-09 master c2dc27d643) [x86_64-linux]
                                                                                             
1)
File.utime allows Time instances in the far future to set mtime and atime FAILED
Expected 2446 == 559444
to be truthy but was false
/builddir/build/BUILD/ruby-2.7.0-c2dc27d643/spec/ruby/core/file/utime_spec.rb:78:in `block (4 levels) in <top (required)>'
/builddir/build/BUILD/ruby-2.7.0-c2dc27d643/spec/ruby/core/file/utime_spec.rb:3:in `<top (required)>'
/builddir/build/BUILD/ruby-2.7.0-c2dc27d643/spec/ruby/spec_helper.rb:31:in `<top (required)>'
/builddir/build/BUILD/ruby-2.7.0-c2dc27d643/spec/ruby/core/file/utime_spec.rb:1:in `require_relative'
/builddir/build/BUILD/ruby-2.7.0-c2dc27d643/spec/ruby/core/file/utime_spec.rb:1:in `<top (required)>'
/builddir/build/BUILD/ruby-2.7.0-c2dc27d643/tool/lib/test/unit.rb:963:in `require'
/builddir/build/BUILD/ruby-2.7.0-c2dc27d643/tool/lib/test/unit.rb:963:in `block in non_options'
/builddir/build/BUILD/ruby-2.7.0-c2dc27d643/tool/lib/test/unit.rb:957:in `each'
/builddir/build/BUILD/ruby-2.7.0-c2dc27d643/tool/lib/test/unit.rb:957:in `non_options'
/builddir/build/BUILD/ruby-2.7.0-c2dc27d643/tool/lib/test/unit.rb:65:in `process_args'
/builddir/build/BUILD/ruby-2.7.0-c2dc27d643/tool/lib/test/unit.rb:131:in `process_args'
/builddir/build/BUILD/ruby-2.7.0-c2dc27d643/tool/lib/test/unit.rb:1151:in `process_args'
/builddir/build/BUILD/ruby-2.7.0-c2dc27d643/tool/lib/test/unit.rb:1156:in `run'
/builddir/build/BUILD/ruby-2.7.0-c2dc27d643/tool/lib/test/unit.rb:1163:in `run'
/builddir/build/BUILD/ruby-2.7.0-c2dc27d643/tool/test/runner.rb:22:in `<top (required)>'
./test/runner.rb:11:in `require_relative'
./test/runner.rb:11:in `<main>'
[/ | ==================100%================== | 00:00:00]      1F      0E 

Finished in 0.009331 seconds

2 files, 5 examples, 15 expectations, 1 failure, 0 errors, 0 tagged
make: *** [uncommon.mk:782: yes-test-all] Error 1
~~~



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

Unsubscribe: <mailto:[email protected]?subject=unsubscribe>
<http://lists.ruby-lang.org/cgi-bin/mailman/options/ruby-core>
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.