/** * (non-PHPdoc) * @see mock/LimeMockStateInterface#invoke($method, $parameters) */ public function invoke(LimeMockMethod $method, array $parameters = null) { $invocation = new LimeMockInvocation($method, is_null($parameters) ? array() : $parameters); $invocation = new LimeMockInvocationExpectation($invocation, $this->output); if (is_null($parameters)) { $invocation->withAnyParameters(); } else { $invocation->withParameters($parameters); } $this->behaviour->expect($invocation); return $invocation; }