You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
It should be possible to disable Micronaut validation via configuration micronaut.validator.enabled = false.
This is useful, for example, in tests that want to send/read invalid data and make assertions about it. Note: For simplicity, the linked example application disables the validator in the actual application, not just in the tests.
Actual Behaviour
Exception is thrown:
Unexpected error occurred: Failed to inject value for parameter [validator] of class: io.micronaut.validation.validator.DefaultValidatorFactory
Message: No bean of type [io.micronaut.validation.validator.Validator] exists. The following matching beans are disabled by bean requirements:
* Bean of type [io.micronaut.validation.validator.DefaultValidator] is disabled because:
- Property [micronaut.validator.enabled] with value [false] does not equal required value: true
Expected Behavior
It should be possible to disable Micronaut validation via configuration
micronaut.validator.enabled = false
.This is useful, for example, in tests that want to send/read invalid data and make assertions about it.
Note: For simplicity, the linked example application disables the validator in the actual application, not just in the tests.
Actual Behaviour
Exception is thrown:
Steps To Reproduce
ValidatorTest
in the example application.Environment Information
No response
Example Application
https://github.com/mancze/micronaut-sandbox/tree/repro/validation-disabled
Version
4.4.3
The text was updated successfully, but these errors were encountered: