Sha256: 1e82d88088f2b48583f6621403f38976c1cb4bff7dcedde2b13e66a50c6970c3
Contents?: true
Size: 532 Bytes
Versions: 26
Compression:
Stored size: 532 Bytes
Contents
#!/usr/bin/env ruby # encoding: UTF-8 require File.expand_path('../test_helper', __FILE__) class ExceptionsTest < TestCase def test_profile result = begin RubyProf.profile do raise(RuntimeError, 'Test error') end rescue end assert_kind_of(RubyProf::Profile, result) end def test_profile_allows_exceptions assert_raises(RuntimeError) do RubyProf.profile(:allow_exceptions => true) do raise(RuntimeError, 'Test error') end end end end
Version data entries
26 entries across 26 versions & 2 rubygems