1
0
mirror of https://github.com/php/php-src.git synced 2026-04-21 23:18:13 +02:00
Files
archived-php-src/ext/random/tests/02_engine/mt19937_error.phpt
T
Tim Düsterhus 53ca24d46e Improve phrasing in argument value errors in ext/random (#9206)
This rephrases the error message for argument errors to be a proper English
sentence.

Co-authored-by: Máté Kocsis <kocsismate@woohoolabs.com>
2022-07-31 19:27:28 +02:00

15 lines
295 B
PHP

--TEST--
Random: Engine: Mt19937: error pattern
--FILE--
<?php
try {
new \Random\Engine\Mt19937(1234, 2);
} catch (\ValueError $e) {
echo $e->getMessage(), PHP_EOL;
}
?>
--EXPECT--
Random\Engine\Mt19937::__construct(): Argument #2 ($mode) must be either MT_RAND_MT19937 or MT_RAND_PHP