Sha256: f24667eebb68e15d78faac15020118f45e353ccebbc037121e174c0505cc14f5
Contents?: true
Size: 967 Bytes
Versions: 15
Compression:
Stored size: 967 Bytes
Contents
require File.dirname(__FILE__) + '/../../../test_helper' module Spec module Api module Helper class ShouldSatisfyTest < Test::Unit::TestCase def test_should_raise_exception_when_block_yields_false assert_raise(ExpectationNotMetError) do 5.should.satisfy {|target| false } end end def test_should_not_raise_exception_when_block_yields_true assert_nothing_raised do 5.should.satisfy {|target| true } end end # should.not.satisfy def test_should_raise_exception_when_block_yields_false_again assert_raise(ExpectationNotMetError) do 5.should.not.satisfy {|target| true } end end def test_should_not_raise_exception_when_block_yields_true_again assert_nothing_raised do 5.should.not.satisfy {|target| false } end end end end end end
Version data entries
15 entries across 15 versions & 1 rubygems