silverstripe-framework/tests/php/Forms/EmailFieldTest/TestValidator.php

25 lines
442 B
PHP
Raw Normal View History

2016-10-14 03:30:05 +02:00
<?php
namespace SilverStripe\Forms\Tests\EmailFieldTest;
use Exception;
use SilverStripe\Forms\Validator;
use SilverStripe\ORM\ValidationResult;
2016-10-14 03:30:05 +02:00
class TestValidator extends Validator
{
public function validationError(
$fieldName, $message, $messageType = ValidationResult::TYPE_ERROR, $cast = ValidationResult::CAST_TEXT
) {
2016-10-14 03:30:05 +02:00
throw new Exception($message);
}
public function javascript()
{
}
public function php($data)
{
}
}