Beispiel #1
0
        public void sortByTest()
        {
            LessonList list_course = new LessonList(new Lesson[]
            {
                new Lesson("אמינות", "תרגול", 1, "בוריס", "ב", 15, 18, 3, 2, "F114"),
                new Lesson("בדיקות", "מעבדה", 1, "בוריס", "שני", 15, 18, 3, 2, "F114"),
                new Lesson("קומפילציה", "הרצאה", 1, "בוריס", "ראשון", 10, 12, 2, 3, "F111"),
            });
            LessonList list_type = new LessonList(new Lesson[]
            {
                new Lesson("קומפילציה", "הרצאה", 1, "בוריס", "ראשון", 10, 12, 2, 3, "F111"),
                new Lesson("בדיקות", "מעבדה", 1, "בוריס", "שני", 15, 18, 3, 2, "F114"),
                new Lesson("אמינות", "תרגול", 1, "בוריס", "ב", 15, 18, 3, 2, "F114"),
            });

            LessonList list_to_sort_course = new LessonList(new Lesson[]
            {
                new Lesson("קומפילציה", "הרצאה", 1, "בוריס", "ראשון", 10, 12, 2, 3, "F111"),
                new Lesson("אמינות", "תרגול", 1, "בוריס", "ב", 15, 18, 3, 2, "F114"),
                new Lesson("בדיקות", "מעבדה", 1, "בוריס", "שני", 15, 18, 3, 2, "F114"),
            });
            LessonList list_to_sort_type = new LessonList(new Lesson[]
            {
                new Lesson("אמינות", "תרגול", 1, "בוריס", "ב", 15, 18, 3, 2, "F114"),
                new Lesson("קומפילציה", "הרצאה", 1, "בוריס", "ראשון", 10, 12, 2, 3, "F111"),
                new Lesson("בדיקות", "מעבדה", 1, "בוריס", "שני", 15, 18, 3, 2, "F114"),
            });

            list_to_sort_course.sortBy("course", true);
            list_to_sort_type.sortBy("type", true);
            Assert.IsTrue(list_to_sort_course.isSameLessonList(list_course));
            Assert.IsTrue(list_to_sort_type.isSameLessonList(list_type));
        }
Beispiel #2
0
 public void isSameLessonListTest()
 {
     Assert.IsTrue(list2.isSameLessonList(list3));
     Assert.IsFalse(list2.isSameLessonList(list1));
 }