Make InputHandler an instance #88

Closed
opened 3 months ago by kimimaru · 1 comments
Owner

Similar to #82 and #86, do the same for the InputHandler.

It is sufficient to simply create an IInputHandler interface and an InputHandler implementation that does exactly what the current one does. Create an instance at the root level and inject it where needed.

Similar to https://codeberg.org/kimimaru/TRBot/issues/82 and https://codeberg.org/kimimaru/TRBot/issues/86, do the same for the `InputHandler`. It is sufficient to simply create an `IInputHandler` interface and an `InputHandler` implementation that does exactly what the current one does. Create an instance at the root level and inject it where needed.
kimimaru added this to the TRBot 2.4 project 3 months ago
kimimaru added the
refactor
label 3 months ago
Poster
Owner

Completed in e6fb5ae9fa, but needs testing for stability.

It will be a good idea to use NSubstitute now that it's possible to mock most of the dependencies. That should be done in another issue and on another branch.

Completed in https://codeberg.org/kimimaru/TRBot/commit/e6fb5ae9fad9b952a8ed5c60d9143b1f37f9395d, but needs testing for stability. It will be a good idea to use [NSubstitute](https://www.nuget.org/packages/NSubstitute/) now that it's possible to mock most of the dependencies. That should be done in another issue and on another branch.
kimimaru closed this issue 3 months ago
Sign in to join this conversation.
No Milestone
No project
No Assignees
1 Participants
Notifications
Due Date

No due date set.

Dependencies

This issue currently doesn't have any dependencies.

Loading…
There is no content yet.