Refactor command exception classes #352
Labels
best practices
Improve the health of the codebase
good first issue
Good for newcomers
hacktoberfest
This issue qualifies for the hacktoberfest event
help wanted
Extra attention is needed
java
Pull requests that update Java code
up for grabs
Any issue that is up for grabs
Milestone
Task Context
At the moment,
NotRecognizedCommandException
andNotSupportedCommandException
both extendRuntimeException
. However, instead of using the taking advantage of howRuntimeException
handles error messages, these custom exception classes use areason
field. This task is to take better advantage of whatRuntimeException
has builtin to its logic.Acceptance Criteria / Goals
Refactor both command exception classes to take advantage of the
message
field of theRuntimeException
class instead of using the currentreason
field.See the following
RuntimeException
constructor:After making these changes, add simple unit tests for both command exception classes as well.
Additional Notes
Please refer to CONTRIBUTING.md for info on how to setup, build, run, and test this project. Feel free to ping @jmakhack in the comments below with any questions if needed. Also, join the Discord to meet and engage with other contributors!
The text was updated successfully, but these errors were encountered: