Code Coverage |
||||||||||
Classes and Traits |
Functions and Methods |
Lines |
||||||||
Total | |
100.00% |
1 / 1 |
|
100.00% |
1 / 1 |
CRAP | |
100.00% |
3 / 3 |
BoolBuildConstraintTrait | |
100.00% |
1 / 1 |
|
100.00% |
1 / 1 |
1 | |
100.00% |
3 / 3 |
buildConstraint | |
100.00% |
1 / 1 |
1 | |
100.00% |
3 / 3 |
<?php | |
declare(strict_types=1); | |
namespace Korobochkin\WPKit\DataComponents\Traits\Special\Bool; | |
use Symfony\Component\Validator\Constraints; | |
/** | |
* Trait BoolBuildConstraintTrait | |
* @package Korobochkin\WPKit\DataComponents\Traits\Special\Bool | |
*/ | |
trait BoolBuildConstraintTrait | |
{ | |
public function buildConstraint() | |
{ | |
return array( | |
new Constraints\NotNull(), | |
new Constraints\Type( | |
array( | |
'type' => 'bool', | |
) | |
), | |
); | |
} | |
} |