Sha256: c846fc6d3074ef7e33f7289809cfe2988fb709e6f658695a5e92b164876cba59
Contents?: true
Size: 559 Bytes
Versions: 11
Compression:
Stored size: 559 Bytes
Contents
#!/usr/bin/env ruby require 'test/unit' require 'ruby-debug' class TestCatchCommand < Test::Unit::TestCase class MockState attr_accessor :message def context; end def confirm(msg); true end def print(*args) @message = *args end end # regression test for bug #20156 def test_catch_does_not_blow_up state = MockState.new catch_cmd = Debugger::CatchCommand.new(state) assert(catch_cmd.match('catch off')) catch(:debug_error) do catch_cmd.execute end assert_equal(nil, state.message) end end
Version data entries
11 entries across 11 versions & 1 rubygems