/** * @expectedException \DMS\Filter\Exception\InvalidCallbackException */ public function testRuleWithNonClosure() { $this->rule->expects($this->once())->method('getInputType')->will($this->returnValue(CallbackRule::CLOSURE_TYPE)); $this->rule->callback = "i'm not a closure"; $result = $this->filter->apply($this->rule, 'value'); }