From 6cc661011fb923f5173f1457f1543f9d17c37582 Mon Sep 17 00:00:00 2001 From: fdai7921 Date: Wed, 7 Feb 2024 15:52:31 +0100 Subject: [PATCH] Finalizing documentation in AdministrationTest file --- src/test/java/org/example/AdministrationTest.java | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/src/test/java/org/example/AdministrationTest.java b/src/test/java/org/example/AdministrationTest.java index b5aa94f..b223cf4 100644 --- a/src/test/java/org/example/AdministrationTest.java +++ b/src/test/java/org/example/AdministrationTest.java @@ -72,6 +72,10 @@ class AdministrationTest { assertEquals(student, student2); } + /** + * Test case for the addCourse method. + * Adds a course to the Administration instance and checks if it can be found by its ID. + */ @Test void addCourse() { Administration admin = new Administration(); @@ -80,6 +84,10 @@ class AdministrationTest { assertEquals(course, admin.findCourseByID("M101")); } + /** + * Test case for the deleteCourse method. + * Adds a course, deletes it, and checks if it's no longer found. + */ @Test public void testDeleteCourse() { Administration administration = new Administration(); @@ -94,6 +102,10 @@ class AdministrationTest { assertNull(administration.findCourseByID("M101")); } + /** + * Test case for the findCourseByID method. + * Adds a course and checks if it can be found by its ID. + */ @Test public void testFindCourseByID() { Administration administration = new Administration();