Skip to content

Commit

Permalink
Resolve merge conflict
Browse files Browse the repository at this point in the history
  • Loading branch information
qinxutan committed Mar 19, 2024
1 parent 7007226 commit 1488ea1
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ public class TutorialClass {
* Initializes the {@code value} field to an empty string and creates an empty list for {@code students}.
*/
public TutorialClass() {
this.value = "";
this.tutorialName = "";
this.students = new ArrayList<>();
}

Expand Down
2 changes: 1 addition & 1 deletion src/main/java/seedu/address/ui/ModuleCard.java
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ public class ModuleCard extends UiPart<Region> {
public ModuleCard(ModuleCode moduleCode) {
super(FXML);
this.moduleCode = moduleCode;
moduleCodeLabel.setText(moduleCode.value);
moduleCodeLabel.setText(moduleCode.getModule().toString());
tutorialClassLabel.setText(moduleCode.getTutorialClasses().toString());
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -105,7 +105,7 @@ void testToString_success() {
@Test
void testEmptyConstructor() {
TutorialClass tutorialClass = new TutorialClass();
assertEquals("", tutorialClass.value);
assertEquals("", tutorialClass.getTutorialClass().toString());
try {
Field field = TutorialClass.class.getDeclaredField("students");
field.setAccessible(true); // Allow access to private field
Expand Down Expand Up @@ -137,7 +137,7 @@ void testConstructorWithStudents() {
students.add(student2);

TutorialClass tutorialClass = new TutorialClass(VALID_TUTORIAL, students);
assertEquals(VALID_TUTORIAL, tutorialClass.value);
assertEquals(VALID_TUTORIAL, tutorialClass.getTutorialClass().toString());
assertEquals(2, tutorialClass.getStudents().size()); // Accessing students via getter
assertTrue(tutorialClass.getStudents().contains(student1));
assertTrue(tutorialClass.getStudents().contains(student2));
Expand Down

0 comments on commit 1488ea1

Please sign in to comment.