Added some unit tests.

This commit is contained in:
Jan Böhmer 2019-03-26 23:34:40 +01:00
parent 1c7155d4e7
commit 943d235b8b
9 changed files with 562 additions and 40 deletions

View file

@ -30,6 +30,7 @@
namespace App\Security\Annotations;
use Doctrine\Common\Annotations\Annotation;
use \InvalidArgumentException;
/**
* @Annotation
@ -100,8 +101,9 @@ class ColumnSecurity
return false;
case 'datetime':
$date = new \DateTime();
return $date->setTimestamp(0);
default:
throw new InvalidArgumentException('Unknown type! You have to specify a placeholder!');
}
}