/** * @expectedException ehough_mockery_mockery_Exception */ public function testDucktypeConstraintThrowsExceptionWhenConstraintUnmatched() { $this->mock->shouldReceive('foo')->with(ehough_mockery_Mockery::ducktype('quack', 'swim'))->once(); $this->mock->foo(new Mockery_Duck_Nonswimmer()); $this->container->mockery_verify(); }