Sha256: ddff8368ac963310b59965ff3e44cd7309304c0252a03c88a1b159e4b27f1f85
Contents?: true
Size: 570 Bytes
Versions: 1
Compression:
Stored size: 570 Bytes
Contents
require 'rspec' require 'abstractivator/exception_ext' require 'stringio' describe Exception do describe '#print_full_trace' do it 'prints the full trace including causes' do io = StringIO.new begin begin raise ArgumentError, 'x must not be nil' rescue => e raise 'there was an error' end rescue => e e.print_full_trace e.print_full_trace(io) end expect(io.string).to match /RuntimeError: there was an error.*Caused by.*ArgumentError: x must not be nil/m end end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
abstractivator-0.12.0 | spec/lib/exception_ext_spec.rb |