Sha256: 1b98fbd9c1867881fd72c95763b1ce456c1d726cc5a53a6a1931856eed3392fd

Contents?: true

Size: 344 Bytes

Versions: 3

Compression:

Stored size: 344 Bytes

Contents

require 'psych/helper'

module Psych
  class TestNil < TestCase
    def test_nil
      yml = Psych.dump nil
      assert_equal "--- \n...\n", yml
      assert_equal nil, Psych.load(yml)
    end

    def test_array_nil
      yml = Psych.dump [nil]
      assert_equal "---\n- \n", yml
      assert_equal [nil], Psych.load(yml)
    end

  end
end

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
psych-1.2.0 test/psych/test_nil.rb
psych-1.1.1 test/psych/test_nil.rb
psych-1.1.0 test/psych/test_nil.rb