respect-validation/tests/unit/Rules
Henrique Moody 238f2d506a
Update validation engine
There are a few "problems" with the current engine:

- Allowing each rule to execute assert() and check() means duplication
  in some cases.

- Because we use exceptions to assert/check, we can only invert a
  validation (with Not) if there are errors. That means that we have
  limited granularity control.

- There is a lot of logic in the exceptions. That means that even after
  it throws an exception, something could still happen. We're stable on
  that front, but I want to simplify them. Besides, debugging exception
  code is painful because the stack trace does not go beyond the
  exception.

Apart from that, there are many limitations with templating, and working
that out in the current implementation makes it much harder.

These changes will improve the library in many aspects, but they will
also change the behavior and break backward compatibility. However,
that's a price I'm willing to pay for the improvements we'll have.

Signed-off-by: Henrique Moody <henriquemoody@gmail.com>
2024-02-22 16:54:44 +01:00
..
AbstractCompositeTest.php Create named-constructors for "Stub" rule 2024-02-04 19:50:49 +01:00
AbstractEnvelopeTest.php Use "Stub" instead of mocking "Validatable" 2024-02-04 19:56:12 +01:00
AbstractRuleTest.php Create named-constructors for "Stub" rule 2024-02-04 19:50:49 +01:00
AbstractSearcherTest.php Upgrade "phpunit/phpunit" 2024-01-28 14:16:52 +01:00
AbstractWrapperTest.php Create named-constructors for "Stub" rule 2024-02-04 19:50:49 +01:00
AllOfTest.php Use "iterable" for Data Providers of RuleTestCase 2024-02-04 20:01:37 +01:00
AlnumTest.php Use a single line to describe return type 2024-02-04 20:04:40 +01:00
AlphaTest.php Use a single line to describe return type 2024-02-04 20:04:40 +01:00
AlwaysInvalidTest.php Use a single line to describe return type 2024-02-04 20:04:40 +01:00
AlwaysValidTest.php Use a single line to describe return type 2024-02-04 20:04:40 +01:00
AnyOfTest.php Use "iterable" for Data Providers of RuleTestCase 2024-02-04 20:01:37 +01:00
ArrayTypeTest.php Use a single line to describe return type 2024-02-04 20:04:40 +01:00
ArrayValTest.php Use a single line to describe return type 2024-02-04 20:04:40 +01:00
Base64Test.php Use a single line to describe return type 2024-02-04 20:04:40 +01:00
BaseTest.php Use a single line to describe return type 2024-02-04 20:04:40 +01:00
BetweenTest.php Use a single line to describe return type 2024-02-04 20:04:40 +01:00
BoolTypeTest.php Use a single line to describe return type 2024-02-04 20:04:40 +01:00
BoolValTest.php Use a single line to describe return type 2024-02-04 20:04:40 +01:00
BsnTest.php Use a single line to describe return type 2024-02-04 20:04:40 +01:00
CallableTypeTest.php Use a single line to describe return type 2024-02-04 20:04:40 +01:00
CallbackTest.php Use a single line to describe return type 2024-02-04 20:04:40 +01:00
CallTest.php Use a single line to describe return type 2024-02-04 20:04:40 +01:00
CharsetTest.php Use a single line to describe return type 2024-02-04 20:04:40 +01:00
CnhTest.php Use a single line to describe return type 2024-02-04 20:04:40 +01:00
CnpjTest.php Use a single line to describe return type 2024-02-04 20:04:40 +01:00
ConsonantTest.php Use a single line to describe return type 2024-02-04 20:04:40 +01:00
ContainsAnyTest.php Use a single line to describe return type 2024-02-04 20:04:40 +01:00
ContainsTest.php Use a single line to describe return type 2024-02-04 20:04:40 +01:00
ControlTest.php Use a single line to describe return type 2024-02-04 20:04:40 +01:00
CountableTest.php Use a single line to describe return type 2024-02-04 20:04:40 +01:00
CountryCodeTest.php Use a single line to describe return type 2024-02-04 20:04:40 +01:00
CpfTest.php Use a single line to describe return type 2024-02-04 20:04:40 +01:00
CreditCardTest.php Use a single line to describe return type 2024-02-04 20:04:40 +01:00
CurrencyCodeTest.php Use a single line to describe return type 2024-02-04 20:04:40 +01:00
DateTest.php Use a single line to describe return type 2024-02-04 20:04:40 +01:00
DateTimeTest.php Use a single line to describe return type 2024-02-04 20:04:40 +01:00
DecimalTest.php Use a single line to describe return type 2024-02-04 20:04:40 +01:00
DigitTest.php Use a single line to describe return type 2024-02-04 20:04:40 +01:00
DirectoryTest.php Use a single line to describe return type 2024-02-04 20:04:40 +01:00
DomainTest.php Use a single line to describe return type 2024-02-04 20:04:40 +01:00
EachTest.php Update validation engine 2024-02-22 16:54:44 +01:00
EmailTest.php Use a single line to describe return type 2024-02-04 20:04:40 +01:00
EndsWithTest.php Use a single line to describe return type 2024-02-04 20:04:40 +01:00
EqualsTest.php Use a single line to describe return type 2024-02-04 20:04:40 +01:00
EquivalentTest.php Use a single line to describe return type 2024-02-04 20:04:40 +01:00
EvenTest.php Use a single line to describe return type 2024-02-04 20:04:40 +01:00
ExecutableTest.php Use a single line to describe return type 2024-02-04 20:04:40 +01:00
ExistsTest.php Use a single line to describe return type 2024-02-04 20:04:40 +01:00
ExtensionTest.php Use a single line to describe return type 2024-02-04 20:04:40 +01:00
FactorTest.php Use a single line to describe return type 2024-02-04 20:04:40 +01:00
FalseValTest.php Use a single line to describe return type 2024-02-04 20:04:40 +01:00
FibonacciTest.php Use a single line to describe return type 2024-02-04 20:04:40 +01:00
FileTest.php Use a single line to describe return type 2024-02-04 20:04:40 +01:00
FilterVarTest.php Use a single line to describe return type 2024-02-04 20:04:40 +01:00
FiniteTest.php Use a single line to describe return type 2024-02-04 20:04:40 +01:00
FloatTypeTest.php Use a single line to describe return type 2024-02-04 20:04:40 +01:00
FloatValTest.php Use a single line to describe return type 2024-02-04 20:04:40 +01:00
GraphTest.php Use a single line to describe return type 2024-02-04 20:04:40 +01:00
GreaterThanTest.php Use a single line to describe return type 2024-02-04 20:04:40 +01:00
HexRgbColorTest.php Use a single line to describe return type 2024-02-04 20:04:40 +01:00
IbanTest.php Use a single line to describe return type 2024-02-04 20:04:40 +01:00
IdenticalTest.php Use a single line to describe return type 2024-02-04 20:04:40 +01:00
ImageTest.php Use a single line to describe return type 2024-02-04 20:04:40 +01:00
ImeiTest.php Use a single line to describe return type 2024-02-04 20:04:40 +01:00
InfiniteTest.php Use a single line to describe return type 2024-02-04 20:04:40 +01:00
InstanceTest.php Use a single line to describe return type 2024-02-04 20:04:40 +01:00
InTest.php Use a single line to describe return type 2024-02-04 20:04:40 +01:00
IntTypeTest.php Use a single line to describe return type 2024-02-04 20:04:40 +01:00
IntValTest.php Use a single line to describe return type 2024-02-04 20:04:40 +01:00
IpTest.php Use a single line to describe return type 2024-02-04 20:04:40 +01:00
IsbnTest.php Use a single line to describe return type 2024-02-04 20:04:40 +01:00
IterableTypeTest.php Use a single line to describe return type 2024-02-04 20:04:40 +01:00
JsonTest.php Use a single line to describe return type 2024-02-04 20:04:40 +01:00
KeyNestedTest.php Use "Stub" instead of mocking "Validatable" 2024-02-04 19:56:12 +01:00
KeySetTest.php Make clear when Stub should not be executed 2024-02-22 16:15:29 +01:00
KeyTest.php Use PHP attributes to define templates 2024-01-29 23:43:57 +01:00
KeyValueTest.php Use a single line to describe return type 2024-02-04 20:04:40 +01:00
LanguageCodeTest.php Use a single line to describe return type 2024-02-04 20:04:40 +01:00
LeapDateTest.php Use a single line to describe return type 2024-02-04 20:04:40 +01:00
LeapYearTest.php Use a single line to describe return type 2024-02-04 20:04:40 +01:00
LengthTest.php Use a single line to describe return type 2024-02-04 20:04:40 +01:00
LessThanTest.php Use a single line to describe return type 2024-02-04 20:04:40 +01:00
LowercaseTest.php Use a single line to describe return type 2024-02-04 20:04:40 +01:00
LuhnTest.php Use a single line to describe return type 2024-02-04 20:04:40 +01:00
MacAddressTest.php Use a single line to describe return type 2024-02-04 20:04:40 +01:00
MaxAgeTest.php Use a single line to describe return type 2024-02-04 20:04:40 +01:00
MaxTest.php Use a single line to describe return type 2024-02-04 20:04:40 +01:00
MimetypeTest.php Use a single line to describe return type 2024-02-04 20:04:40 +01:00
MinAgeTest.php Use a single line to describe return type 2024-02-04 20:04:40 +01:00
MinTest.php Use a single line to describe return type 2024-02-04 20:04:40 +01:00
MultipleTest.php Use a single line to describe return type 2024-02-04 20:04:40 +01:00
NegativeTest.php Use a single line to describe return type 2024-02-04 20:04:40 +01:00
NfeAccessKeyTest.php Use a single line to describe return type 2024-02-04 20:04:40 +01:00
NifTest.php Use a single line to describe return type 2024-02-04 20:04:40 +01:00
NipTest.php Use a single line to describe return type 2024-02-04 20:04:40 +01:00
NoneOfTest.php Use "iterable" for Data Providers of RuleTestCase 2024-02-04 20:01:37 +01:00
NotBlankTest.php Use a single line to describe return type 2024-02-04 20:04:40 +01:00
NotEmojiTest.php Use a single line to describe return type 2024-02-04 20:04:40 +01:00
NotEmptyTest.php Use a single line to describe return type 2024-02-04 20:04:40 +01:00
NoTest.php Use a single line to describe return type 2024-02-04 20:04:40 +01:00
NotOptionalTest.php Use a single line to describe return type 2024-02-04 20:04:40 +01:00
NotTest.php Use PHP attributes to define templates 2024-01-29 23:43:57 +01:00
NoWhitespaceTest.php Use a single line to describe return type 2024-02-04 20:04:40 +01:00
NullableTest.php Make clear when Stub should not be executed 2024-02-22 16:15:29 +01:00
NullTypeTest.php Use a single line to describe return type 2024-02-04 20:04:40 +01:00
NumberTest.php Use a single line to describe return type 2024-02-04 20:04:40 +01:00
NumericValTest.php Use a single line to describe return type 2024-02-04 20:04:40 +01:00
ObjectTypeTest.php Use a single line to describe return type 2024-02-04 20:04:40 +01:00
OddTest.php Use a single line to describe return type 2024-02-04 20:04:40 +01:00
OneOfTest.php Use "iterable" for Data Providers of RuleTestCase 2024-02-04 20:01:37 +01:00
OptionalTest.php Upgrade "phpunit/phpunit" 2024-01-28 14:16:52 +01:00
PerfectSquareTest.php Use a single line to describe return type 2024-02-04 20:04:40 +01:00
PeselTest.php Use a single line to describe return type 2024-02-04 20:04:40 +01:00
PhoneTest.php Allow templates to have raw and translatable params 2024-02-14 18:08:13 +01:00
PhpLabelTest.php Use a single line to describe return type 2024-02-04 20:04:40 +01:00
PisTest.php Use a single line to describe return type 2024-02-04 20:04:40 +01:00
PolishIdCardTest.php Use a single line to describe return type 2024-02-04 20:04:40 +01:00
PortugueseNifTest.php Add require attributes to "PortugueseNifTest" 2024-02-22 01:51:35 +01:00
PositiveTest.php Use a single line to describe return type 2024-02-04 20:04:40 +01:00
PostalCodeTest.php Use a single line to describe return type 2024-02-04 20:04:40 +01:00
PrimeNumberTest.php Use a single line to describe return type 2024-02-04 20:04:40 +01:00
PrintableTest.php Use a single line to describe return type 2024-02-04 20:04:40 +01:00
PropertyTest.php Make clear when Stub should not be executed 2024-02-22 16:15:29 +01:00
PublicDomainSuffixTest.php Use a single line to describe return type 2024-02-04 20:04:40 +01:00
PunctTest.php Use a single line to describe return type 2024-02-04 20:04:40 +01:00
ReadableTest.php Use a single line to describe return type 2024-02-04 20:04:40 +01:00
RegexTest.php Use a single line to describe return type 2024-02-04 20:04:40 +01:00
ResourceTypeTest.php Use a single line to describe return type 2024-02-04 20:04:40 +01:00
RomanTest.php Use a single line to describe return type 2024-02-04 20:04:40 +01:00
ScalarValTest.php Use a single line to describe return type 2024-02-04 20:04:40 +01:00
SizeTest.php Use a single line to describe return type 2024-02-04 20:04:40 +01:00
SlugTest.php Use a single line to describe return type 2024-02-04 20:04:40 +01:00
SortedTest.php Use a single line to describe return type 2024-02-04 20:04:40 +01:00
SpaceTest.php Use a single line to describe return type 2024-02-04 20:04:40 +01:00
StartsWithTest.php Use a single line to describe return type 2024-02-04 20:04:40 +01:00
StringTypeTest.php Use a single line to describe return type 2024-02-04 20:04:40 +01:00
StringValTest.php Use a single line to describe return type 2024-02-04 20:04:40 +01:00
SubdivisionCodeTest.php Allow templates to have raw and translatable params 2024-02-14 18:08:13 +01:00
SubsetTest.php Use a single line to describe return type 2024-02-04 20:04:40 +01:00
SymbolicLinkTest.php Use a single line to describe return type 2024-02-04 20:04:40 +01:00
TimeTest.php Use a single line to describe return type 2024-02-04 20:04:40 +01:00
TldTest.php Use a single line to describe return type 2024-02-04 20:04:40 +01:00
TrueValTest.php Use a single line to describe return type 2024-02-04 20:04:40 +01:00
TypeTest.php Use a single line to describe return type 2024-02-04 20:04:40 +01:00
UniqueTest.php Use a single line to describe return type 2024-02-04 20:04:40 +01:00
UploadedTest.php Use a single line to describe return type 2024-02-04 20:04:40 +01:00
UppercaseTest.php Use a single line to describe return type 2024-02-04 20:04:40 +01:00
UrlTest.php Use a single line to describe return type 2024-02-04 20:04:40 +01:00
UuidTest.php Use a single line to describe return type 2024-02-04 20:04:40 +01:00
VersionTest.php Use a single line to describe return type 2024-02-04 20:04:40 +01:00
VideoUrlTest.php Use a single line to describe return type 2024-02-04 20:04:40 +01:00
VowelTest.php Use a single line to describe return type 2024-02-04 20:04:40 +01:00
WhenTest.php Update validation engine 2024-02-22 16:54:44 +01:00
WritableTest.php Use a single line to describe return type 2024-02-04 20:04:40 +01:00
XdigitTest.php Use a single line to describe return type 2024-02-04 20:04:40 +01:00
YesTest.php Use a single line to describe return type 2024-02-04 20:04:40 +01:00