respect-validation/tests/integration/rules/arrayVal_4.phpt
2015-10-22 03:22:58 -02:00

16 lines
312 B
PHP

--FILE--
<?php
require 'vendor/autoload.php';
use Respect\Validation\Exceptions\ArrayValException;
use Respect\Validation\Validator as v;
try {
v::not(v::arrayVal())->check([42]);
} catch (ArrayValException $exception) {
echo $exception->getMainMessage();
}
?>
--EXPECTF--
{ 42 } must not be an array