class TestUnitUIMediator
Public Instance Methods
test_raise_interrupt()
click to toggle source
# File test-unit-3.3.4/test/ui/test_testrunmediator.rb, line 6 def test_raise_interrupt raise Interrupt, "from test" end
test_run_suite_with_interrupt_exception()
click to toggle source
# File test-unit-3.3.4/test/ui/test_testrunmediator.rb, line 4 def test_run_suite_with_interrupt_exception test_case = Class.new(Test::Unit::TestCase) do def test_raise_interrupt raise Interrupt, "from test" end end mediator = Test::Unit::UI::TestRunnerMediator.new(test_case.suite) finished = false mediator.add_listener(Test::Unit::UI::TestRunnerMediator::FINISHED) do finished = true end assert_raise(Interrupt) do mediator.run end assert(finished) end