[macruby-changes] [1134] MacRuby/branches/experimental

source_changes at macosforge.org source_changes at macosforge.org
Tue Mar 24 06:56:31 PDT 2009


Revision: 1134
          http://trac.macosforge.org/projects/ruby/changeset/1134
Author:   eloy.de.enige at gmail.com
Date:     2009-03-24 06:56:31 -0700 (Tue, 24 Mar 2009)
Log Message:
-----------
Added failing tests about encoding.

Modified Paths:
--------------
    MacRuby/branches/experimental/Rakefile
    MacRuby/branches/experimental/test_roxor.rb

Modified: MacRuby/branches/experimental/Rakefile
===================================================================
--- MacRuby/branches/experimental/Rakefile	2009-03-24 13:46:41 UTC (rev 1133)
+++ MacRuby/branches/experimental/Rakefile	2009-03-24 13:56:31 UTC (rev 1134)
@@ -1,3 +1,5 @@
+# encoding: utf-8
+
 # See ./rakelib/*.rake for all tasks.
 
 desc "Same as all"

Modified: MacRuby/branches/experimental/test_roxor.rb
===================================================================
--- MacRuby/branches/experimental/test_roxor.rb	2009-03-24 13:46:41 UTC (rev 1133)
+++ MacRuby/branches/experimental/test_roxor.rb	2009-03-24 13:56:31 UTC (rev 1134)
@@ -1393,4 +1393,13 @@
 
   assert "true", "p(Dir['*.c'].length > 1)"
   assert "true", "p(Dir.glob('*.c').length > 1)"
+
 end
+
+test "encoding" do
+
+  assert "US-ASCII", "File.open('Rakefile', 'r:US-ASCII') {|f| puts f.read.encoding.name }"
+
+  assert ":ok", "puts ':ok'.encode('US-ASCII')"
+
+end
\ No newline at end of file
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.macosforge.org/pipermail/macruby-changes/attachments/20090324/37ebdbf9/attachment-0001.html>


More information about the macruby-changes mailing list