Closed arogachev closed 3 months ago
.github/workflows/bc.yml
, .github/workflows/bench.yml
, .github/workflows/build.yml
, and .github/workflows/composer-require-checker.yml
from 8.0
to 8.1
.CHANGELOG.md
file for version 2.0.0
.composer.json
from 8.0
to 8.1
..docs/guide/en/client-side-validation.md
, .docs/guide/en/configuring-rules-via-php-attributes.md
, .docs/guide/en/creating-custom-rules.md
, .docs/guide/en/customizing-error-messages.md
, .docs/guide/en/result.md
, .docs/guide/en/using-validator.md
.messages/de/yii-validator.php
.
messages/pl/yii-validator.php
, the following changes were made:'The data must have at least "{min}" filled attributes.'
was changed to 'At least {min, number} {min, plural, one{attribute} other{attributes}} from this list must be filled'
.'The value must be either "{true}" or "{false}".'
was changed to '{Attribute} must be either "{true}" or "{false}".'
.'This value must be an array or implement \Countable interface.'
was changed to '{Attribute} must be an array or implement \Countable interface.'
.'This value must contain at least {min, number} {min, plural, one{item} other{items}}.'
was changed to '{Attribute} must contain at least {min, number} {min, plural, one{item} other{items}}.'
.'This value must contain at most {max, number} {max, plural, one{item} other{items}}.'
was changed to '{Attribute} must contain at most {max, number} {max, plural, one{item} other{items}}.'
.'This value must contain exactly {exactly, number} {exactly, plural, one{item} other{items}}.'
was changed to '{Attribute} must contain exactly {exactly, number} {exactly, plural, one{item} other{items}}.'
.'Value must be array or iterable.'
was changed to '{Attribute} must be array or iterable.'
.'Value must be an integer.'
was changed to '{Attribute} must be an integer.'
.'The value is not JSON.'
was changed to '{Attribute} is not JSON.'
.'This value must contain at least {min, number} {min, plural, one{character} other{characters}}.'
was changed to '{Attribute} must contain at least {min, number} {min, plural, one{character} other{characters}}.'
.'This value must contain at most {max, number} {max, plural, one{character} other{characters}}.'
was changed to '{Attribute} must contain at most {max, number} {max, plural, one{character} other{characters}}.'
.'This value must contain exactly {exactly, number} {exactly, plural, one{character} other{characters}}.'
was changed to '{Attribute} must contain exactly {exactly, number} {exactly, plural, one{character} other{characters}}.'
.'Value must be equal to "{targetValueOrAttribute}".'
was changed to '{Attribute} must be equal to "{targetValueOrAttribute}".'
.'Value must be strictly equal to "{targetValueOrAttribute}".'
was changed to '{Attribute} must be strictly equal to "{targetValueOrAttribute}".'
.'Value must not be equal to "{targetValueOrAttribute}".'
was changed to '{Attribute} must not be equal to "{targetValueOrAttribute}".'
.'Value must not be strictly equal to "{targetValueOrAttribute}".'
was changed to '{Attribute} must not be strictly equal to "{targetValueOrAttribute}".'
.'Value must be greater than "{targetValueOrAttribute}".'
was changed to '{Attribute} must be greater than "{targetValueOrAttribute}".'
.'Value must be greater than or equal to "{targetValueOrAttribute}".'
was changed to '{Attribute} must be greater than or equal to "{targetValueOrAttribute}".'
.'Value must be less than "{targetValueOrAttribute}".'
was changed to '{Attribute} must be less than "{targetValueOrAttribute}".'
.'Value must be less than or equal to "{targetValueOrAttribute}".'
was changed to '{Attribute} must be less than or equal to "{targetValueOrAttribute}"."'
.messages/ru/yii-validator.php
, the following changes were made:'The data must have at least "{min}" filled attributes.'
was changed to 'At least {min, number} {min, plural, one{attribute} other{attributes}} from this list must be filled'
.'The value must be either "{true}" or "{false}".'
was changed to '{Attribute} must be either "{true}" or "{false}".'
.'This value must be an array or implement \Countable interface.'
was changed to '{Attribute} must be an array or implement \Countable interface.'
.'This value must contain at least {min, number} {min, plural, one{item} other{items}}.'
was changed to '{Attribute} must contain at least {min, number} {min, plural, one{item} other{items}}.'
.'This value must contain at most {max, number} {max, plural, one{item} other{items}}.'
was changed to '{Attribute} must contain at most {max, number} {max, plural, one{item} other{items}}.'
.'This value must contain exactly {exactly, number} {exactly, plural, one{item} other{items}}.'
was changed to '{Attribute} must contain exactly {exactly, number} {exactly, plural, one{item} other{items}}.'
.'Value must be array or iterable.'
was changed to '{Attribute} must be array or iterable.'
.'Value must be an integer.'
was changed to '{Attribute} must be an integer.'
.'The value is not JSON.'
was changed to '{Attribute} is not JSON.'
.'This value must contain at least {min, number} {min, plural, one{character} other{characters}}.'
was changed to '{Attribute} must contain at least {min, number} {min, plural, one{character} other{characters}}.'
.'This value must contain at most {max, number} {max, plural, one{character} other{characters}}.'
was changed to '{Attribute} must contain at most {max, number} {max, plural, one{character} other{characters}}.'
.'This value must contain exactly {exactly, number} {exactly, plural, one{character} other{characters}}.'
was changed to '{Attribute} must contain exactly {exactly, number} {exactly, plural, one{character} other{characters}}.'
.'Value must be equal to "{targetValueOrAttribute}".'
was changed to '{Attribute} must be equal to "{targetValueOrAttribute}".'
.'Value must be strictly equal to "{targetValueOrAttribute}".'
was changed to '{Attribute} must be strictly equal to "{targetValueOrAttribute}".'
.'Value must not be equal to "{targetValueOrAttribute}".'
was changed to '{Attribute} must not be equal to "{targetValueOrAttribute}".'
.'Value must not be strictly equal to "{targetValueOrAttribute}".'
was changed to '{Attribute} must not be strictly equal to "{targetValueOrAttribute}".'
.'Value must be greater than "{targetValueOrAttribute}".'
was changed to '{Attribute} must be greater than "{targetValueOrAttribute}".'
.'Value must be greater than or equal to "{targetValueOrAttribute}".'
was changed to '{Attribute} must be greater than or equal to "{targetValueOrAttribute}".'
.'Value must be less than "{targetValueOrAttribute}".'
was changed to '{Attribute} must be less than "{targetValueOrAttribute}".'
.'Value must be less than or equal to "{targetValueOrAttribute}".'
was changed to '{Attribute} must be less than or equal to "{targetValueOrAttribute}".'
.'Exactly 1 attribute from this list must be filled: {attributes}.'
.messages/uz/yii-validator.php
has the following changes:'The data must have at least "{min}" filled attributes.'
was changed to 'At least {min, number} {min, plural, one{attribute} other{attributes}} from this list must be filled'
.'Value must be either "{true}" or "{false}".'
was changed to '{Attribute} must be either "{true}" or "{false}".'
.'This value must be an array or implement \Countable interface.'
was changed to '{Attribute} must be an array or implement \Countable interface.'
.'This value must contain at least {min, number} {min, plural, one{item} other{items}}.'
was changed to '{Attribute} must contain at least {min, number} {min, plural, one{item} other{items}}.'
.'This value must contain at most {max, number} {max, plural, one{item} other{items}}.'
was changed to '{Attribute} must contain at most {max, number} {max, plural, one{item} other{items}}.'
.'This value must contain exactly {exactly, number} {exactly, plural, one{item} other{items}}.'
was changed to '{Attribute} must contain exactly {exactly, number} {exactly, plural, one{item} other{items}}.'
.'Value must be array or iterable.'
was changed to '{Attribute} must be array or iterable.'
.'Value must be a valid email address.'
was changed to '{Attribute} is not a valid email address.'
.'This value is not in the list of acceptable values.'
was changed to '{Attribute} is not in the list of acceptable values.'
.'Must be a valid IP address.'
was changed to '{Attribute} must be a valid IP address.'
.'Must not be an IPv4 address.'
was changed to '{Attribute} must not be an IPv4 address.'
.'Must not be an IPv6 address.'
was changed to '{Attribute} must not be an IPv6 address.'
.'Contains wrong subnet mask.'
was changed to '{Attribute} contains wrong subnet mask.'
.'Must be an IP address with specified subnet.'
was changed to '{Attribute} must be an IP address with specified subnet.'
.'Must not be a subnet.'
was changed to '{Attribute} must not be a subnet.'
.'Is not in the allowed range.'
was changed to '{Attribute} is not in the allowed range.'
.'Value must be an integer.'
was changed to '{Attribute} must be an integer.'
.'The value is not JSON.'
was changed to '{Attribute} is not JSON.'
.'This value must contain at least {min, number} {min, plural, one{character} other{characters}}.'
was changed to '{Attribute} must contain at least {min, number} {min, plural, one{character} other{characters}}.'
.'This value must contain at most {max, number} {max, plural, one{character} other{characters}}.'
was changed to '{Attribute} must contain at most {max, number} {max, plural, one{character} other{characters}}.'
.'This value must contain exactly {exactly, number} {exactly, plural, one{character} other{characters}}.'
was changed to '{Attribute} must contain exactly {exactly, number} {exactly, plural, one{character} other{characters}}.'
.'The value must be an array or an object.'
was changed to '{Attribute} must be an array or an object.'
.'The allowed types are integer, float, string, boolean, null and object implementing \Stringable interface or \DateTimeInterface.'
was changed to 'The allowed types are integer, float, string, boolean, null and object implementing \Stringable interface or \DateTimeInterface.'
.'The attribute value returned from a custom data set must have one of the following types: integer, float, string, boolean, null or an object implementing \Stringable interface or \DateTimeInterface.'
was changed to 'The attribute value returned from a custom data set must have one of the following types: integer, float, string, boolean, null or an object implementing \Stringable interface or \DateTimeInterface.'
.'Value must be equal to "{targetValueOrAttribute}".'
was changed to '{Attribute} must be equal to "{targetValueOrAttribute}".'
.'Value must be strictly equal to "{targetValueOrAttribute}".'
was changed to '{Attribute} must be strictly equal to "{targetValueOrAttribute}".'
.'Value must not be equal to "{targetValueOrAttribute}".'
was changed to '{Attribute} must not be equal to "{targetValueOrAttribute}".'
.'Value must not be strictly equal to "{targetValueOrAttribute}".'
was changed to '{Attribute} must not be strictly equal to "{targetValueOrAttribute}".'
.'Value must be greater than "{targetValueOrAttribute}".'
was changed to '{Attribute} must be greater than "{targetValueOrAttribute}".'
.'Value must be greater than or equal to "{targetValueOrAttribute}".'
was changed to '{Attribute} must be greater than or equal to "{targetValueOrAttribute}".'
.'Value must be less than "{targetValueOrAttribute}".'
was changed to '{Attribute} must be less than "{targetValueOrAttribute}".'
.'Value must be less than or equal to "{targetValueOrAttribute}".'
was changed to '{Attribute} must be less than or equal to "{targetValueOrAttribute}".'
.DataSet/ObjectDataSet.php
has the following changes:ObjectDataSet
now implements LabelsProviderInterface
.DumpedRuleInterface.php
was renamed to RuleWithOptionsInterface.php
.ObjectParser.php
has the following changes:getLabels()
was added.getValidationPropertyLabels()
was added.RulesDumper.php
has the following changes:RulesDumper
now uses the interface DumpedRuleInterface
instead of RuleWithOptionsInterface
.Label.php
was added.LabelsProviderInterface.php
was added.Result.php
has the following changes:$errors
now has the type list<Error>
.getErrorMessages()
now returns list<string>
.getErrorMessagesIndexedByAttribute()
now returns list<string>
.getAttributeErrors()
now returns list<Error>
.getAttributeErrorMessages()
now returns list<string>
.getCommonErrorMessages()
now returns list<string>
.
AbstractCompare
class now implements the interface DumpedRuleInterface
instead of RuleWithOptionsInterface
.AbstractNumber
class now implements the interface DumpedRuleInterface
instead of RuleWithOptionsInterface
.AtLeast
class now implements the interface DumpedRuleInterface
instead of RuleWithOptionsInterface
.AtLeastHandler
class now uses the trait TranslatedAttributesHandlerTrait
.BooleanValue
class now implements the interface DumpedRuleInterface
instead of RuleWithOptionsInterface
.BooleanValueHandler
class now uses the trait TranslatedAttributesHandlerTrait
.Callback
class now implements the interface DumpedRuleInterface
instead of RuleWithOptionsInterface
.Compare
class no longer implements the getName
method.CompareHandler
class now uses the trait TranslatedAttributesHandlerTrait
.Composite
class now implements the interface DumpedRuleInterface
instead of RuleWithOptionsInterface
.Count
class now implements the interface DumpedRuleInterface
instead of RuleWithOptionsInterface
.CountHandler
class now uses the trait TranslatedAttributesHandlerTrait
.DateTime
class, implementing the interface DumpedRuleInterface
, with various properties and methods.DateTimeHandler
class that implements the RuleHandlerInterface
and handles the validation of DateTime
rules.
Each.php
file to implement the DumpedRuleInterface
and added a new constant PARAMETER_EACH_KEY
.EachHandler.php
file to use the new constant PARAMETER_EACH_KEY
and added a new entry in the validation result.Email.php
file to implement the DumpedRuleInterface
and changed the error messages.EmailHandler.php
file to use the Attribute
context variable in the error messages.getName()
method from Equal.php
, GreaterThan.php
, GreaterThanOrEqual.php
, In.php
, Integer.php
, Ip.php
, Json.php
, Length.php
, LessThan.php
, LessThanOrEqual.php
, and Nested.php
files.In.php
file to implement the DumpedRuleInterface
and changed the error message.InHandler.php
file to use the Attribute
context variable in the error message.Integer.php
file to implement the DumpedRuleInterface
and changed the error message.Ip.php
file to implement the DumpedRuleInterface
and changed the error messages.IpHandler.php
file to use the Attribute
context variable in the error messages and added a new validation check method.Json.php
file to implement the DumpedRuleInterface
and changed the error messages.JsonHandler.php
file to use the Attribute
context variable in the error messages and added a new validation check method.Length.php
file to implement the DumpedRuleInterface
and changed the error messages.LengthHandler.php
file to use the Attribute
context variable in the error messages.Nested.php
file to implement the DumpedRuleInterface
and changed the error messages.
'Attribute' => $context->getCapitalizedTranslatedAttribute()
argument in multiple places in the NestedHandler
, NumberHandler
, OneOfHandler
, RegexHandler
, RequiredHandler
, SubsetHandler
, and StringValueHandler
classes. This adds the capitalized attribute name to the error messages.getName()
method in the NotEqual
, Number
, OneOf
, Regex
, Required
, StopOnError
, StringValue
, and Subset
classes. The method no longer exists.Number
class (notNumberMessage
, lessThanMinMessage
, and greaterThanMaxMessage
) to include the capitalized attribute name.OneOf
class (message
) to include the attribute name in the error message.Regex
class (message
) to include the attribute name in the error message.Required
class (message
and notPassedMessage
) to include the attribute name in the error message.StringValue
class (message
) to include the attribute name in the error message.Subset
class (message
and incorrectInputMessage
) to include the attribute name in the error message.CapitalizedTranslatedAttribute()
method in the ValidationContext
class.getFormattedAttributesString()
and getCapitalizedAttributesString()
methods in the TranslatedAttributesHandlerTrait
trait.
src/Rule/Trait/TranslatedAttributesHandlerTrait.php
.src/Rule/TrueValue.php
:
TrueValue
to TrueValueHandler
.RuleWithOptionsInterface
.{Attribute} must be "{true}".
src/Rule/TrueValueHandler.php
:
getCommonResultParameters
method: 'Attribute'
.src/Rule/Url.php
:
Url
to UrlHandler
.RuleWithOptionsInterface
.{Attribute} is not a valid URL.
src/Rule/UrlHandler.php
:
{Attribute} is not a valid URL.
src/ValidationContext.php
:
setAttributeLabel
to set the attribute label.getAttributeLabel
to retrieve the attribute label.getTranslatedAttribute
to return the attribute label if set, otherwise the attribute name.getCapitalizedTranslatedAttribute
to return the capitalized attribute label.src/Validator.php
:
LabelsProviderInterface
object.tests/ConfigTest.php
:
Url
rule in the Russian translation category source.tests/DataSet/ObjectDataSetTest.php
:
getValidationPropertyLabels
to the ObjectWithLabelsProvider
class.LabelsProviderInterface
.tests/Helper/ObjectParserTest.php
:
tests/Helper/RulesDumperTest.php
:
tests/Helper/RulesNormalizerTest.php
:
tests/Rule/AtLeastTest.php
was modified:use InvalidArgumentException;
use Yiisoft\Validator\ValidationContext;
testMinGreaterThanAttributesCount
which tests for an InvalidArgumentException
and a specific exception message when the min
value is greater than the number of attributes.testGetName
test to check for the correct class name.testAttributeIsNull
which tests if an attribute is null.dataOptions
method to change the message templates for various scenarios.dataOptions
method.dataValidationFailed
method.testSkipOnError
method to change the rule instance being tested.testWhen
method to change the rule instance being tested.getDifferentRuleInHandlerItems
to return a different rule instance.testWhen
method to change the rule instance being tested.tests/Rule/Base/RuleWithOptionsTestTrait.php
was modified:use Yiisoft\Validator\RuleWithOptionsInterface;
to use Yiisoft\Validator\DumpedRuleInterface;
.public function testOptions(RuleWithOptionsInterface $rule, array $expectedOptions)
to public function testOptions(DumpedRuleInterface $rule, array $expectedOptions)
.tests/Rule/Base/RuleWithProvidedRulesTrait.php
was modified:use Yiisoft\Validator\RuleWithOptionsInterface;
to use Yiisoft\Validator\DumpedRuleInterface;
.private function testGetOptionsWithNotRuleInternal($ruleClassName): void
to private function testGetOptionsWithNotRuleInternal(string $ruleClassName): void
.tests/Rule/BooleanValueTest.php
was modified:testGetName
test to check for the correct class name.dataOptions
method to change the message templates for various scenarios.dataValidationFailed
method to change the message templates for various scenarios.tests/Rule/CallbackTest.php
was modified:testGetName
test to check for the correct class name.tests/Rule/CompareTest.php
was modified:use
statement: use function is_string;
.testGetName
test to check for the correct class name.dataOptions
method to change the message templates for various scenarios.dataValidationFailed
method.__toString
method to use the correct attribute name.dataValidationFailedWithDifferentTypes
method.
tests/Rule/CompositeTest.php
was modified. Yiisoft\Validator\Rule\Callback
was added.testGetName()
method was changed to use the Composite::class
constant instead of the string 'composite'
.dataOptions()
method were modified. The 'number'
rule was replaced with 'Number::class'
in three places.dataOptions()
method were modified. The string 'Value'
was replaced with 'Attribute'
in multiple places.dataOptions()
method were modified. The strings 'Value'
and 'Attribute'
were replaced with placeholders {Attribute}
.Yiisoft\Validator\Rule\Number
was added.'test'
was replaced with 'RuleWithoutOptions::class'
.Yiisoft\Validator\Rule\Required
was added.'required'
was replaced with 'Required::class'
in the data options.getOptions()
method were modified. The strings 'Value'
and 'Attribute'
were replaced with placeholders {Attribute}
.tests/Rule/CountTest.php
was modified.Yiisoft\Validator\Rule\Count
was added.testGetName()
method was changed to use the Count::class
constant instead of the string 'count'
.dataOptions()
method were modified. The 'differentRuleInHandlerTestTrait'
rule was replaced with 'DifferentRuleInHandlerTestTrait'
.dataOptions()
method were modified. The string 'This value'
was replaced with 'Value'
in multiple places.dataValidationFailed()
method was modified. The string 'Min - 3'
was replaced with 'Value'
.dataValidationFailed()
method were modified. The string 'Min - 3'
was replaced with 'Value'
.dataValidationFailed()
method were modified. The string 'Max - 3'
was replaced with 'Value'
.dataValidationFailed()
method were modified. The string 'Exactly - 3'
was replaced with 'Value'
.tests/Rule/DateTimeTest.php
was added.tests/Rule/DateTimeTest.php
was added.tests/Rule/EachTest.php
file:
use
statements for stdClass
, Callback
, StringValue
, Validator
, and ValidationContext
classes.testGetName()
method to assert that the rule's name is equal to Each::class
.dataOptions()
method to update the incorrectInputMessage
templates.dataContextEachKey()
and testContextEachKey()
methods for testing each key in a context.testNestedContextEachKey()
method for testing nested context each keys.tests/Rule/EmailTest.php
file:
testGetName()
method to assert that the rule's name is equal to Email::class
.dataOptions()
method to update the incorrectInputMessage
and message
templates.tests/Rule/EqualTest.php
file:
testGetName()
method to assert that the rule's name is equal to Equal::class
.dataOptions()
method to update the message
template.tests/Rule/GreaterThanOrEqualTest.php
file:
testGetName()
method to assert that the rule's name is equal to GreaterThanOrEqual::class
.dataOptions()
method to update the message
template.tests/Rule/GreaterThanTest.php
file:
testGetName()
method to assert that the rule's name is equal to GreaterThan::class
.dataOptions()
method to update the message
template.tests/Rule/InTest.php
file:
testGetName()
method to assert that the rule's name is equal to In::class
.dataOptions()
method to update the message
template.tests/Rule/JsonTest.php
file:
testGetName()
method to assert that the rule's name is equal to Json::class
.dataOptions()
method to update the incorrectInputMessage
and message
templates.tests/Rule/LengthTest.php
, the import statement for Yiisoft\Validator\Tests\Rule\Base\DifferentRuleInHandlerTestTrait
was changed and moved to a different line.testGetName
was updated to use $rule->getName()
instead of hardcoding the value.dataOptions
method in the same file, modifying the 'template'
values of various messages.dataValidationFailed
method of the same file, the values of the messages 'incorrectInputMessage'
, 'greaterThanMaxMessage'
, 'notExactlyMessage'
, and 'lessThanMinMessage'
were modified.tests/Rule/LessThanOrEqualTest.php
, the test case testGetName
was updated to use $rule->getName()
instead of hardcoding the value.tests/Rule/LessThanTest.php
, the test case testGetName
was updated to use $rule->getName()
instead of hardcoding the value.tests/Rule/NotEqualTest.php
, the test case testGetName
was updated to use $rule->getName()
instead of hardcoding the value.tests/Rule/NumberTest.php
, the test case testGetName
was updated to use $rule->getName()
instead of hardcoding the value.dataOptions
method in the same file, modifying the 'template'
values of various messages.tests/Rule/OneOfTest.php
, the test case testGetName
was updated to use $rule->getName()
instead of hardcoding the value.dataOptions
method in the same file, modifying the 'template'
values of various messages.dataValidationFailed
method of the same file, the value of the message 'incorrectInputMessage'
was modified.dataValidationFailed
method of the same file, the value of the message 'message'
was modified.dataValidationFailed
method of the same file, the value of the message 'message'
was modified.dataValidationFailed
method of the same file, the value of the message 'message'
was modified.dataValidationFailed
method of the same file, the value of the message 'message'
was modified.dataValidationFailed
method of the same file, the value of the message 'message'
was modified.dataValidationFailed
method of the same file, the value of the message 'message'
was modified.dataValidationFailed
method of the same file, the value of the message 'message'
was modified.dataValidationFailed
method of the same file, the value of the message 'message'
was modified.dataValidationFailed
method of the same file, the value of the message 'message'
was modified.dataValidationFailed
method of the same file, the value of the message 'message'
was modified.dataValidationFailed
method of the same file, the value of the message 'message'
was modified.dataValidationFailed
method of the same file, the value of the message 'message'
was modified.dataValidationFailed
method of the same file, the value of the message 'message'
was modified.dataValidationFailed
method of the same file, the value of the message 'message'
was modified.dataValidationFailed
method of the same file, the value of the message 'message'
was modified.dataValidationFailed
method of the same file, the value of the message 'message'
was modified.dataValidationFailed
method of the same file, the value of the message 'message'
was modified.dataValidationFailed
method of the same file, the value of the message 'message'
was modified.
tests/Rule/RegexTest.php
:
getName
method to return the class name instead of 'regex'.incorrectInputMessage
.message
.dataValidationFailed
.dataValidationFailed
test data to use attribute placeholders in the error messages.tests/Rule/RequiredTest.php
:
message
.notPassedMessage
.getName
method to return the class name instead of 'required'.tests/Rule/RuleWithBuiltInHandler.php
:
getName
method.tests/Rule/StopOnErrorTest.php
:
getName
method to return the class name instead of 'stopOnError'.dataValidationFailed
test data to use attribute placeholders in the error messages.tests/Rule/StringValueTest.php
:
getName
method to return the class name instead of 'string'.dataValidationFailed
test data to use attribute placeholders in the error messages.tests/Rule/SubsetTest.php
:
getName
method to return the class name instead of 'subset'.tests/Rule/TrueValueTest.php
:
getName
method to return the class name instead of 'isTrue'.dataValidationFailed
test data to use attribute placeholders in the error messages.
UrlTest.php
, the getName()
method of the Url
class was changed from returning the string 'url'
to returning the class Url::class
. In the dataOptions()
and dataValidationFailed()
methods, the $incorrectInputErrors
and $errors
arrays were updated to include attribute placeholders in their error messages.AtLeastDto.php
, the class now implements the AttributeTranslatorProviderInterface
and defines the getAttributeLabels()
and getAttributeTranslator()
methods.ObjectForTestingCache1.php
and ObjectForTestingDisabledCache.php
, the Label
attribute was added to the $c
property.ObjectWithLabelsProvider.php
was added, containing a class that implements the LabelsProviderInterface
and defines the getValidationPropertyLabels()
method.OneOfDto.php
, the class now implements the AttributeTranslatorProviderInterface
and defines the getAttributeLabels()
and getAttributeTranslator()
methods.CustomUrlRuleSet.php
, the getName()
method was removed.NotNull.php
, the getName()
method was removed.RuleWithCustomHandler.php
, the getName()
method was removed.RuleWithoutOptions.php
, the getName()
method was removed.StubDumpedRule.php
was renamed from StubRuleWithOptions.php
.NestedTest.php
, the error messages in the test data were updated to include attribute placeholders.ValidationContextTest.php
, the setAttributeLabel()
method was added to set a custom attribute label, and the related tests were added.
669 was merged incorrectly.