mirror of
https://github.com/Respect/Validation.git
synced 2026-03-22 17:54:41 +01:00
15 lines
278 B
PHP
15 lines
278 B
PHP
--FILE--
|
|
<?php
|
|
require 'vendor/autoload.php';
|
|
|
|
use Respect\Validation\Validator as v;
|
|
use Respect\Validation\Exceptions\DigitException;
|
|
|
|
try {
|
|
v::not(v::digit())->check(1);
|
|
} catch(DigitException $e) {
|
|
echo $e->getMainMessage();
|
|
}
|
|
|
|
--EXPECTF--
|
|
1 must not contain digits (0-9)
|