summaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
authornaruse <naruse@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2014-04-23 02:41:54 +0000
committernaruse <naruse@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2014-04-23 02:41:54 +0000
commitd4c6c4c8c86b828ab941c8ac29fe6894210c5b9f (patch)
tree7e4ddc6a53a84d61f264368edd9f47255a1b52c9 /test
parent0f69c1845a1d60399a6362e9e9332324e2a254e2 (diff)
check whther ext4+ or not
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@45679 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'test')
-rw-r--r--test/ruby/test_io.rb6
1 files changed, 4 insertions, 2 deletions
diff --git a/test/ruby/test_io.rb b/test/ruby/test_io.rb
index 4654ec3ea7..21f85c284c 100644
--- a/test/ruby/test_io.rb
+++ b/test/ruby/test_io.rb
@@ -1672,7 +1672,10 @@ class TestIO < Test::Unit::TestCase
case f.statfs.type
when 0x9123683E # BTRFS_SUPER_MAGIC
when 0x7461636f # OCFS2_SUPER_MAGIC
- when 0xEF53 # EXT4_SUPER_MAGIC
+ when 0xEF53 # EXT2_SUPER_MAGIC EXT3_SUPER_MAGIC EXT4_SUPER_MAGIC
+ # ext3's timestamp resolution is seconds
+ s = f.stat
+ stat.mtime.nsec != 0 || stat.atime.nsec != 0 || stat.ctime.nsec != 0
when 0x58465342 # XFS_SUPER_MAGIC
when 0x01021994 # TMPFS_MAGIC
else
@@ -1682,7 +1685,6 @@ class TestIO < Test::Unit::TestCase
true
end
-
def test_seek
make_tempfile {|t|
open(t.path) { |f|