diff options
Diffstat (limited to 'test/psych/visitors')
-rw-r--r-- | test/psych/visitors/test_yaml_tree.rb | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/test/psych/visitors/test_yaml_tree.rb b/test/psych/visitors/test_yaml_tree.rb index b3890bcd72..5755f5863e 100644 --- a/test/psych/visitors/test_yaml_tree.rb +++ b/test/psych/visitors/test_yaml_tree.rb @@ -156,6 +156,12 @@ module Psych assert_equal(-1, Psych.load(Psych.dump(-1 / 0.0)).infinite?) end + def test_string + assert_match(/'017'/, Psych.dump({'a' => '017'})) + assert_match(/'019'/, Psych.dump({'a' => '019'})) + assert_match(/'01818'/, Psych.dump({'a' => '01818'})) + end + # http://yaml.org/type/null.html def test_nil assert_cycle nil |