for testing and deploying your application
for finding and fixing issues
for empowering human code reviews
<?php
namespace Redaxscript\Tests\Validator;
use Redaxscript\Tests\TestCaseAbstract;
use Redaxscript\Validator;
/**
* UserTest
*
* @since 4.3.0
* @package Redaxscript
* @category Tests
* @author Henry Ruhs
* @covers Redaxscript\Validator\Name
*/
class NameTest extends TestCaseAbstract
{
* testGetPattern
public function testGetPattern() : void
/* setup */
$validator = new Validator\Name();
/* actual */
$actual = $validator->getPattern();
/* compare */
$this->assertIsString($actual);
}
* testValidate
* @param string $name
* @param bool $expect
* @dataProvider providerAutoloader
public function testValidate(string $name = null, bool $expect = null) : void
$actual = $validator->validate($name);
$this->assertEquals($expect, $actual);