Check all requests have handlers #839
-
Currently the application starts even it there is an IRequest that has no handler. If I try to execute that request throws an exception that there is no handler in available in dependency injection. Is it possible to check that each request in the assembly has a handler registered? Either to just throw an error at startup or to run something in a pipeline that that throws an exception. |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments 1 reply
-
With an integration test, yes. Look for concrete types that implement |
Beta Was this translation helpful? Give feedback.
-
May this help? |
Beta Was this translation helpful? Give feedback.
May this help?
https://codeopinion.com/find-mediatr-requests-without-handlers/