prophesize(DelegateInterface::class); $delegate->process($argument)->willReturn($response ?: new Response()); return $delegate; } /** * @return Prophet */ private static function getProphet() { if (static::$prophet === null) { static::$prophet = new Prophet(); } return static::$prophet; } }