Flowdock
assert_nothing_thrown(msg=nil) public

No documentation

This method has no description. You can help the Ruby community by adding new notes.

Hide source
# File lib/test/unit/assertions.rb, line 53
      def assert_nothing_thrown(msg=nil)
        begin
          yield
        rescue ArgumentError => error
          raise error if /\Auncaught throw (.+)\z/ !~ error.message
          msg = message(msg) { "<#{$1}> was thrown when nothing was expected" }
          flunk(msg)
        end
        assert(true, "Expected nothing to be thrown")
      end
Register or log in to add new notes.