Pretty-print arrays on failure
问题 describe Rspec do it 'should print arrays in a readable manner' do arr = [ [0, :a, -1], [1, :b, -2], [2, :c, -3], [3, :d, -4], [4, :e, -5], [6, :g, -7], [7, :h, -8], [8, :i, -9] ] arr.should eql [] end end On failure: Failures: 1) Rspec should print arrays in a readable manner Failure/Error: arr.should eql [] expected: [] got: [[0, :a, -1], [1, :b, -2], [2, :c, -3], [3, :d, -4], [4, :e, -5], [6, :g, -7], [7, :h, -8], [8, :i, -9]] Is there a way to tell Rspec to pretty print its failures? My