summaryrefslogtreecommitdiff
path: root/test/psych/test_array.rb
blob: f006cc866cea441a8e9a7b6e1d38c236731e8b68 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
require_relative 'helper'

module Psych
  class TestArray < TestCase
    def setup
      super
      @list = [{ :a => 'b' }, 'foo']
    end

    def test_self_referential
      @list << @list
      assert_cycle(@list)
    end

    def test_cycle
      assert_cycle(@list)
    end
  end
end