diff options
| author | aamine <aamine@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2005-01-26 15:16:09 +0000 |
|---|---|---|
| committer | aamine <aamine@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2005-01-26 15:16:09 +0000 |
| commit | 42f027df1aa350fe6aab29abb24ef56864e3c8d7 (patch) | |
| tree | c2bf9e5d2df4ba92b0b4fe0c47ce573006ece3a9 /test/fileutils/fileasserts.rb | |
| parent | d0dea3fd4435da335ac5ae6319a0d1bd8496f707 (diff) | |
| download | ruby-42f027df1aa350fe6aab29abb24ef56864e3c8d7.tar.gz ruby-42f027df1aa350fe6aab29abb24ef56864e3c8d7.tar.xz ruby-42f027df1aa350fe6aab29abb24ef56864e3c8d7.zip | |
* test/fileutils/test_fileutils.rb (setup): support BSD-style directory group inheritance. (backport from HEAD, rev 1.32)
* test/fileutils/fileasserts.rb (assert_same_entry): show entry difference. (backport from HEAD, rev 1.4)
git-svn-id: http://svn.ruby-lang.org/repos/ruby/branches/ruby_1_8@7836 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'test/fileutils/fileasserts.rb')
| -rw-r--r-- | test/fileutils/fileasserts.rb | 19 |
1 files changed, 7 insertions, 12 deletions
diff --git a/test/fileutils/fileasserts.rb b/test/fileutils/fileasserts.rb index ea0353454..c2e9244a9 100644 --- a/test/fileutils/fileasserts.rb +++ b/test/fileutils/fileasserts.rb @@ -13,18 +13,13 @@ module Test end def assert_same_entry(from, to) - _wrap_assertion { - assert_block("entry #{from} != #{to}") { - a = File.stat(from) - b = File.stat(to) - - a.mode == b.mode and - #a.atime == b.atime and - a.mtime == b.mtime and - a.uid == b.uid and - a.gid == b.gid - } - } + a = File.stat(from) + b = File.stat(to) + assert_equal a.mode, b.mode, "mode #{a.mode} != #{b.mode}" + #assert_equal a.atime, b.atime + assert_equal a.mtime, b.mtime, "mtime #{a.mtime} != #{b.mtime}" + assert_equal a.uid, b.uid, "uid #{a.uid} != #{b.uid}" + assert_equal a.gid, b.gid, "gid #{a.gid} != #{b.gid}" end def assert_file_exist(path) |
