phpmock\Mock::call PHP Method

call() public method

This method is called from the namespaced function.
public call ( array $arguments ) : mixed
$arguments array the call arguments.
return mixed
    public function call(array $arguments)
    {
        return call_user_func_array($this->function, $arguments);
    }

Usage Example

コード例 #1
0
ファイル: Spy.php プロジェクト: php-mock/php-mock
 public function call(array $arguments)
 {
     $return = null;
     $exception = null;
     try {
         $return = parent::call($arguments);
         return $return;
     } catch (\Exception $e) {
         $exception = $e;
         throw $e;
     } finally {
         $this->invocations[] = new Invocation($arguments, $return, $exception);
     }
 }
All Usage Examples Of phpmock\Mock::call