Skip to content

Commit

Permalink
Fix checkstyle
Browse files Browse the repository at this point in the history
  • Loading branch information
Remy9926 committed Nov 14, 2023
1 parent cd4b820 commit 71b8303
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
2 changes: 1 addition & 1 deletion src/main/java/seedu/duke/data/Date.java
Original file line number Diff line number Diff line change
Expand Up @@ -66,4 +66,4 @@ public static Date now() throws Exception {
Date now = new Date(LocalDate.now().format(toStringFormatter), false);
return now;
}
}
}
8 changes: 4 additions & 4 deletions src/test/java/seedu/duke/parser/ParserTest.java
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ public void parse_emptyInput_returnsIncorrect() {
}

@Test
public void parse_unknownCommandWord_returnsHelp() {
public void parse_unknownCommandWord_returnsHelp() throws Exception {
final String input = "unknowncommandword arguments arguments";
parseAndAssertCommandType(input, HelpCommand.class);
}
Expand All @@ -38,13 +38,13 @@ public void parse_unknownCommandWord_returnsHelp() {
*/

@Test
public void parse_helpCommand_parsedCorrectly() {
public void parse_helpCommand_parsedCorrectly() throws Exception {
final String input = "help";
parseAndAssertCommandType(input, HelpCommand.class);
}

@Test
public void parse_exitCommand_parsedCorrectly() {
public void parse_exitCommand_parsedCorrectly() throws Exception {
final String input = "exit";
parseAndAssertCommandType(input, ExitCommand.class);
}
Expand All @@ -56,7 +56,7 @@ public void parse_exitCommand_parsedCorrectly() {
/**
* Asserts that parsing the given inputs will return IncorrectCommand with the given feedback message.
*/
private void parseAndAssertIncorrectWithMessage(String feedbackMessage, String... inputs) {
private void parseAndAssertIncorrectWithMessage(String feedbackMessage, String... inputs) throws Exception {
for (String input : inputs) {
final IncorrectCommand result = parseAndAssertCommandType(input, IncorrectCommand.class);
assertEquals(result.feedbackToUser, feedbackMessage);
Expand Down

0 comments on commit 71b8303

Please sign in to comment.