public void SchoolTestAddCourseSecondTime() { var course = new Course("Javascript"); var school = new School("Boby Georgiev"); school.AddCourse(course); school.AddCourse(course); }
public void TestRemoveCourseNormalRemoval() { School school = new School(); school.AddCourse(new Course("Chemistry")); school.AddCourse(new Course("Geography")); school.RemoveCourse(new Course("Chemistry")); Assert.IsTrue(school.OfferedCourses.Count == 1); }
public void TestAddCourseNormalAddition() { School school = new School(); school.AddCourse(new Course("Chemistry")); Assert.IsTrue(school.OfferedCourses.Count == 1); }
public void TestHasCourseNullObject() { School school = new School(); school.AddCourse(new Course("Chemistry")); Assert.IsFalse(school.HasCourse(null)); }
public void TestHasCourseMissingCourse() { School school = new School(); school.AddCourse(new Course("Chemistry")); Assert.IsFalse(school.HasCourse(new Course("Biology"))); }
public void TestHasCourseExistingCourse() { School school = new School(); school.AddCourse(new Course("Chemistry")); Assert.IsTrue(school.HasCourse(new Course("Chemistry"))); }
public void SchoolAddCourseTest() { School school = new School(); Course course = new Course("HQPC"); school.AddCourse(course); Assert.AreEqual("HQPC", course.Name, "Adding courses to school works incorrectly."); }
public void SchoolTestRemoveExistentStudent() { var course = new Course("Javascript"); var school = new School("TUES"); school.AddCourse(course); school.RemoveCourse(course); }
public void SchoolTestRemoveNonExistingCourse() { var firstCourse = new Course("Javascript"); var secondCourse = new Course("Csharp"); var school = new School("TUES"); school.AddCourse(firstCourse); school.RemoveCourse(secondCourse); }
public void SchoolAddStudentInCourseTest() { School cSharpSchool = new School("C# School"); Course cSharpCourse = new Course("C# Course"); cSharpSchool.AddCourse(cSharpCourse); Assert.AreEqual(1, cSharpSchool.CountOfCourses()); }
public void SchoolRemoveStudentFromCourseTest() { School cSharpSchool = new School("C# School"); Course cSharpCourse = new Course("C# Course"); cSharpSchool.AddCourse(cSharpCourse); cSharpSchool.RemoveCourse(cSharpCourse); Assert.AreEqual(0, cSharpSchool.CountOfCourses()); }
static void Main(string[] args) { School school = new School(); Course<Student> course = new Course<Student>(); Student student = new Student("A",10000); course[0] = student; school.AddCourse(course); }
public void School_ChecIsNotkUniqeNumber() { School school = new School(); Course<Student> course = new Course<Student>(); Student student = new Student("Anonymouse",10000); course[0] = student; school.AddCourse(course); bool falseCondition = School.CheckForTrueUniqeNumber(10000); Assert.IsFalse(falseCondition,"Probably Uniqe Number funcionalty issue in the School class."); }
public void TestAddCourseAlreadyAddedCourse() { School school = new School(); school.AddCourse(new Course("Chemistry")); school.AddCourse(new Course("Chemistry")); }
public void SchoolAddCourseNullTest() { School school = new School(); school.AddCourse(null); }
public void TestRemoveCourseMissingCourse() { School school = new School(); school.AddCourse(new Course("Chemistry")); school.RemoveCourse(new Course("Geography")); }
public void TestAddCourseNullObject() { School school = new School(); school.AddCourse(null); }
public void TestToString() { School school = new School(); Course course = new Course("Chemistry"); course.AddStudent(new Student("Hari", 123)); course.AddStudent(new Student("Joe", 124)); school.AddCourse(course); string expectedOutput = "Course name: Chemistry" + Environment.NewLine + "Student: Hari, number: 123." + Environment.NewLine + "Student: Joe, number: 124."; Assert.AreEqual(expectedOutput, school.ToString()); }