public void SchoolShouldRemoveCourseCorrectly() { var school = new School("Telerik Academy"); var course = new Course("High Quality Code"); school.AddCourse(course); school.RemoveCourse(course); Assert.AreEqual(0, school.Courses.Count); }
public void RemoveCourseShouldRemoveCourseThatAlreadyExist() { string name = "English"; List<Student> students = new List<Student>(); Course newCourse = new Course(students,name); List<Course> courses = new List<Course>(); School IodaSchool = new School(courses); IodaSchool.AddCourse(newCourse); IodaSchool.RemoveCourse(newCourse); }
public void RemoveCourseShouldThrowErrorIfCourseDoesNotExist() { string name = "English"; List<Student> students = new List<Student>(); Course newCourse = new Course(students, name); Course newCourse2 = new Course(students, name + 2); List<Course> courses = new List<Course>(); School IodaSchool = new School(courses); IodaSchool.AddCourse(newCourse); IodaSchool.RemoveCourse(newCourse2); }
public void SchoolShouldThrowWhenRemovingNotExistingCourse() { var school = new School("Telerik Academy"); var course = new Course("High Quality Code"); school.RemoveCourse(course); }
public void SchoolShouldThrowExceptionWhenRemovingNullCourse() { var school = new School("Telerik Academy"); Course course = null; school.RemoveCourse(course); }