diff --git a/src/Exceptions/DatasetMissing.php b/src/Exceptions/DatasetMissing.php new file mode 100644 index 00000000..5613d02e --- /dev/null +++ b/src/Exceptions/DatasetMissing.php @@ -0,0 +1,36 @@ + $args A map of argument names to their typee + */ + public function __construct(string $file, string $name, array $args) + { + parent::__construct(sprintf( + "A test with the description '%s' has %d argument(s) ([%s]) and no dataset(s) provided in %s", + $name, + count($args), + implode(', ', array_map(static function (string $arg, string $type): string { + return sprintf('%s $%s', $type, $arg); + }, array_keys($args), $args)), + $file, + )); + } +}