[前][次][番号順一覧][スレッド一覧]

ruby-changes:34355

From: nobu <ko1@a...>
Date: Sun, 15 Jun 2014 10:09:28 +0900 (JST)
Subject: [ruby-changes:34355] nobu:r46436 (trunk): test_file_exhaustive.rb: fix assertion

nobu	2014-06-15 10:09:19 +0900 (Sun, 15 Jun 2014)

  New Revision: 46436

  http://svn.ruby-lang.org/cgi-bin/viewvc.cgi?view=revision&revision=46436

  Log:
    test_file_exhaustive.rb: fix assertion
    
    * test/ruby/test_file_exhaustive.rb (test_expand_path_memsize):
      wrong expected value, considering a prefix (drive letter or UNC)
      on DOSISH platforms.  [Bug #9934]

  Modified files:
    trunk/test/ruby/test_file_exhaustive.rb
Index: test/ruby/test_file_exhaustive.rb
===================================================================
--- test/ruby/test_file_exhaustive.rb	(revision 46435)
+++ test/ruby/test_file_exhaustive.rb	(revision 46436)
@@ -464,7 +464,7 @@ class TestFileExhaustive < Test::Unit::T https://github.com/ruby/ruby/blob/trunk/test/ruby/test_file_exhaustive.rb#L464
     path = File.expand_path("/foo")
     assert_operator(ObjectSpace.memsize_of(path), :<=, path.bytesize, bug9934)
     path = File.expand_path("/a"*25)
-    assert_equal(51, ObjectSpace.memsize_of(path), bug9934)
+    assert_equal(path.bytesize, ObjectSpace.memsize_of(path), bug9934)
   end
 
   def test_expand_path_encoding

--
ML: ruby-changes@q...
Info: http://www.atdot.net/~ko1/quickml/

[前][次][番号順一覧][スレッド一覧]