summaryrefslogtreecommitdiff
path: root/test/yaml
diff options
context:
space:
mode:
authorakira <akira@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2004-02-08 06:43:53 +0000
committerakira <akira@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2004-02-08 06:43:53 +0000
commit54d612c27f60daf293ba97c5cd7ddae330cbfe65 (patch)
treef2ae610f53124c1383972139e9c505147f1793a7 /test/yaml
parent992d2749aca335795b6cd943bf4025f5ff281699 (diff)
* test/yaml/test_yaml.rb (YAML_Unit_Tests::test_range_cycle):
added tests. [ruby-core:02306] [ruby-core:02311] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@5649 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'test/yaml')
-rw-r--r--test/yaml/test_yaml.rb17
1 files changed, 17 insertions, 0 deletions
diff --git a/test/yaml/test_yaml.rb b/test/yaml/test_yaml.rb
index fd9f79b..3597772 100644
--- a/test/yaml/test_yaml.rb
+++ b/test/yaml/test_yaml.rb
@@ -1196,6 +1196,23 @@ EOY
end
#
+ # Test Range cycle
+ #
+ def test_range_cycle
+ #
+ # From Minero Aoki [ruby-core:02306]
+ #
+ t = "a".."z"
+ assert_equal( t, YAML.load( YAML.dump( t ) ) )
+
+ #
+ # From Nobu Nakada [ruby-core:02311]
+ #
+ t = "0".."1"
+ assert_equal( t, YAML.load( YAML.dump( t ) ) )
+ end
+
+ #
# Circular references
#
def test_circular_references