diff --git a/src/test/java/org/example/AdministrationTest.java b/src/test/java/org/example/AdministrationTest.java index e4ac41f..20e879b 100644 --- a/src/test/java/org/example/AdministrationTest.java +++ b/src/test/java/org/example/AdministrationTest.java @@ -79,4 +79,19 @@ class AdministrationTest { admin.addCourse(course); assertEquals(course, admin.findCourseByID("M101")); } + + @Test + public void testDeleteCourse() { + Administration administration = new Administration(); + // Adding a course + Course course = new Course("Math", "M101", 4); + administration.addCourse(course); + + // Deleting the course + assertTrue(administration.deleteCourse("M101")); + + // Checking if the course is no longer found + assertNull(administration.findCourseByID("M101")); + } + } \ No newline at end of file