Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add Meeting Test Cases #111

Merged
merged 4 commits into from
Oct 28, 2020
Merged

Add Meeting Test Cases #111

merged 4 commits into from
Oct 28, 2020

Conversation

MerlinLim
Copy link

@MerlinLim MerlinLim commented Oct 27, 2020

Create Add Command and Model Meeting test cases.

Combined from and to test cases because they are similar

Omit TitleDescrpitionContainsKeyword test cases because it is
similar to NameDescrptionContainsKeyword test case.
@MerlinLim MerlinLim added this to the v1.3 milestone Oct 27, 2020
@MerlinLim MerlinLim self-assigned this Oct 27, 2020
@MerlinLim MerlinLim added this to PRs Pending Approvals in Productiv via automation Oct 27, 2020
This was linked to issues Oct 27, 2020
@@ -52,12 +52,12 @@
public static final String LOCATION_DESC_A = " " + PREFIX_LOCATION + VALID_LOCATION_A;
public static final String LOCATION_DESC_B = " " + PREFIX_LOCATION + VALID_LOCATION_B;

public static final String INVALID_TITLE_DESC = " " + PREFIX_TITLE + "Meeting&"; // '&' not allowed in names
public static final String INVALID_TITLE_DESC = " " + PREFIX_TITLE + ""; // '&' not allowed in names

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think the comment here is outdated

public static final String INVALID_FROM_DESC = " " + PREFIX_FROM + "3-03-2020 09:30"; // missing '0' digit
public static final String INVALID_TO_DESC = " " + PREFIX_TO + "03-03-2020 0930"; // missing colon
public static final String INVALID_CONTACTS_DESC = " " + PREFIX_CONTACTS + "1 2 3"; // no commas
public static final String INVALID_LOCATION_DESC = " " + PREFIX_LOCATION + ""; // 'friend' not allowed in roles

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think this as well?

assertThrows(NullPointerException.class, () -> new Location((String) null));
}

@Test

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is this supposed to be constructor_invalidLocation?

Comment on lines 26 to 40
@Test
public void contains_nullPerson_throwsNullPointerException() {
assertThrows(NullPointerException.class, () -> uniqueMeetingList.contains(null));
}

@Test
public void contains_personNotInList_returnsFalse() {
assertFalse(uniqueMeetingList.contains(MEETING_A));
}

@Test
public void contains_personInList_returnsTrue() {
uniqueMeetingList.add(MEETING_A);
assertTrue(uniqueMeetingList.contains(MEETING_A));
}

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think we can change the method names to meeting here?

Comment on lines +42 to +49
// @Test
// public void contains_MeetingWithSameIdentityFieldsInList_returnsTrue() {
// uniqueMeetingList.add(MEETING_A);
// Meeting editedMeetingA = new MeetingBuilder(MEETING_A).withDescription(VALID_DESCRIPTION_B)
// .build();
// assertTrue(uniqueMeetingList.contains(editedMeetingA));
// }

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should we delete this comment or add a TODO comment?

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Maybe add a TODO comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Okayy

Maybe add a TODO comment

Productiv automation moved this from PRs Pending Approvals to PRs approved / Ready for Testing Oct 28, 2020
@MerlinLim MerlinLim merged commit 3d35680 into AY2021S1-CS2103T-F11-2:master Oct 28, 2020
Productiv automation moved this from PRs approved / Ready for Testing to Issues Done / PRs Merged (After Testing) Oct 28, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
Productiv
Issues Done / PRs Merged (After Testing)
Development

Successfully merging this pull request may close these issues.

Add testing for Meeting Part 1 Add testing for Meeting
2 participants