Sha256: 707acc1a56effb0847285a9c54c2c04d2f89465de0b7971366c31ab31e19e340
Contents?: true
Size: 710 Bytes
Versions: 9
Compression:
Stored size: 710 Bytes
Contents
require File.dirname(__FILE__) + '/../../../test_helper' module Spec module Api class NullObjectTest < Test::Unit::TestCase def setup @mock = Mock.new("null_object", :null_object=>true) end def test_should_ignore_unexpected_methods @mock.random_call("a","d","c") @mock.__verify end def test_should_handle_passing_expectation @mock.should_receive(:something) @mock.something @mock.__verify end def test_should_handle_failing_expectation assert_raises(MockExpectationError) do @mock.should_receive(:something) @mock.__verify end end end end end
Version data entries
9 entries across 9 versions & 1 rubygems