From 1a9281e32e00858b0336b17edb2d0771b7c30683 Mon Sep 17 00:00:00 2001 From: Izn432 Date: Sat, 19 Oct 2024 02:09:41 +0800 Subject: [PATCH] Fix style issues --- .../keycontacts/logic/commands/UnassignPiecesCommandTest.java | 3 ++- .../logic/parser/AssignPiecesCommandParserTest.java | 3 +-- .../java/keycontacts/logic/parser/KeyContactsParserTest.java | 2 +- .../logic/parser/UnassignPiecesCommandParserTest.java | 3 +-- src/test/java/keycontacts/model/util/SampleDataUtilTest.java | 2 +- 5 files changed, 6 insertions(+), 7 deletions(-) diff --git a/src/test/java/keycontacts/logic/commands/UnassignPiecesCommandTest.java b/src/test/java/keycontacts/logic/commands/UnassignPiecesCommandTest.java index 78a0eecac24..2fce70f803b 100644 --- a/src/test/java/keycontacts/logic/commands/UnassignPiecesCommandTest.java +++ b/src/test/java/keycontacts/logic/commands/UnassignPiecesCommandTest.java @@ -115,7 +115,8 @@ public void equals() { assertTrue(identicalCommand.equals(baseCommand)); // different values -> returns false - UnassignPiecesCommand differentIndexCommand = new UnassignPiecesCommand(INDEX_SECOND_STUDENT, bensonPianoPieces); + UnassignPiecesCommand differentIndexCommand = new UnassignPiecesCommand(INDEX_SECOND_STUDENT, + bensonPianoPieces); assertFalse(baseCommand.equals(differentIndexCommand)); UnassignPiecesCommand differentPianoPiecesCommand = new UnassignPiecesCommand(INDEX_FIRST_STUDENT, diff --git a/src/test/java/keycontacts/logic/parser/AssignPiecesCommandParserTest.java b/src/test/java/keycontacts/logic/parser/AssignPiecesCommandParserTest.java index fe72374d960..93a66bb6ba8 100644 --- a/src/test/java/keycontacts/logic/parser/AssignPiecesCommandParserTest.java +++ b/src/test/java/keycontacts/logic/parser/AssignPiecesCommandParserTest.java @@ -48,8 +48,7 @@ public void parse_invalidPreamble_failure() { assertParseFailure(parser, "-1" + PIANO_PIECE_DESC_BEETHOVEN, invalidFormatMessage); assertParseFailure(parser, "0" + PIANO_PIECE_DESC_BEETHOVEN, invalidFormatMessage); assertParseFailure(parser, "1 r" + PIANO_PIECE_DESC_BEETHOVEN, invalidFormatMessage); - assertParseFailure(parser, "1 i/s" + PIANO_PIECE_DESC_BEETHOVEN, - invalidFormatMessage); + assertParseFailure(parser, "1 i/s" + PIANO_PIECE_DESC_BEETHOVEN, invalidFormatMessage); } @Test public void parse_invalidPianoPiece_failure() { diff --git a/src/test/java/keycontacts/logic/parser/KeyContactsParserTest.java b/src/test/java/keycontacts/logic/parser/KeyContactsParserTest.java index 2646f83dbaf..17cb0e868b1 100644 --- a/src/test/java/keycontacts/logic/parser/KeyContactsParserTest.java +++ b/src/test/java/keycontacts/logic/parser/KeyContactsParserTest.java @@ -13,7 +13,6 @@ import java.util.List; import java.util.stream.Collectors; -import keycontacts.logic.commands.UnassignPiecesCommand; import org.junit.jupiter.api.Test; import keycontacts.commons.core.index.Index; @@ -28,6 +27,7 @@ import keycontacts.logic.commands.HelpCommand; import keycontacts.logic.commands.ListCommand; import keycontacts.logic.commands.ScheduleCommand; +import keycontacts.logic.commands.UnassignPiecesCommand; import keycontacts.logic.parser.exceptions.ParseException; import keycontacts.model.lesson.RegularLesson; import keycontacts.model.pianopiece.PianoPiece; diff --git a/src/test/java/keycontacts/logic/parser/UnassignPiecesCommandParserTest.java b/src/test/java/keycontacts/logic/parser/UnassignPiecesCommandParserTest.java index 729704113a0..6b1ae3fac12 100644 --- a/src/test/java/keycontacts/logic/parser/UnassignPiecesCommandParserTest.java +++ b/src/test/java/keycontacts/logic/parser/UnassignPiecesCommandParserTest.java @@ -49,8 +49,7 @@ public void parse_invalidPreamble_failure() { assertParseFailure(parser, "-1" + PIANO_PIECE_DESC_BEETHOVEN, invalidFormatMessage); assertParseFailure(parser, "0" + PIANO_PIECE_DESC_BEETHOVEN, invalidFormatMessage); assertParseFailure(parser, "1 r" + PIANO_PIECE_DESC_BEETHOVEN, invalidFormatMessage); - assertParseFailure(parser, "1 i/s" + PIANO_PIECE_DESC_BEETHOVEN, - invalidFormatMessage); + assertParseFailure(parser, "1 i/s" + PIANO_PIECE_DESC_BEETHOVEN, invalidFormatMessage); } @Test public void parse_invalidPianoPiece_failure() { diff --git a/src/test/java/keycontacts/model/util/SampleDataUtilTest.java b/src/test/java/keycontacts/model/util/SampleDataUtilTest.java index afcf423ee17..fcdebffe979 100644 --- a/src/test/java/keycontacts/model/util/SampleDataUtilTest.java +++ b/src/test/java/keycontacts/model/util/SampleDataUtilTest.java @@ -7,4 +7,4 @@ class SampleDataUtilTest { public void getSampleDirectory_success() { SampleDataUtil.getSampleStudentDirectory(); } -} \ No newline at end of file +}