getMessage(); parent::__construct(sprintf(<<<'EOF' This should not happen - please create an new issue here: https://github.com/pestphp/pest/issues Issue: %s PHP version: %s Operating system: %s EOF , $message, phpversion(), PHP_OS), 1, $exception); } /** * Creates a new instance of should not happen without a specific exception. */ public static function fromMessage(string $message): ShouldNotHappen { return new ShouldNotHappen(new Exception($message)); } }