Ejemplo n.º 1
0
 public void SecondConstructor_ParametrsWithDublicate_GetArgumentNullException()
 {
     //Act
     Classroom classroom = Classroom.Create("room",
                                            new Teacher("teach", "er", new Lesson("sad", 12, 22)),
                                            new Teacher("tea", "cher", new Lesson("as", 11, 42)),
                                            new Teacher("tea", "cher", new Lesson("as", 11, 42)));
 }
Ejemplo n.º 2
0
 public void SecondConstructor_ClassroomParametrsWithDublicate_GetArgumentNullException()
 {
     //Act
     School school = new School(classrooms: new List <Classroom> {
         Classroom.Create("SomeClass1", 1),
         Classroom.Create("SomeClass1", 1),
         Classroom.Create("SomeClass2", 2),
         Classroom.Create("SomeClass2", 2),
         Classroom.Create("SomeClass3", 3),
         Classroom.Create("SomeClass3", 3)
     });
 }
Ejemplo n.º 3
0
        public void FirstCreateMethod_CallFirstConstructor_GetObject()
        {
            //Arrange
            string expectedName   = "room";
            int    expectedNumber = 12;
            //Act
            Classroom classroom = Classroom.Create("room", 12);

            //Assert
            Assert.AreEqual(expectedName, classroom.Name);
            Assert.AreEqual(expectedNumber, classroom.NumberOfTeacher);
        }
Ejemplo n.º 4
0
        public void SecondCreateMethod_CallSecondConstructor_GetObject()
        {
            //Arrange
            string expectedName   = "room";
            int    expectedNumber = 2;
            //Act
            Classroom classroom = Classroom.Create("room",
                                                   new Teacher("teach", "er", new Lesson("sad", 12, 22)),
                                                   new Teacher("tea", "cher", new Lesson("as", 11, 42)));

            //Assert
            Assert.AreEqual(expectedName, classroom.Name);
            Assert.AreEqual(expectedNumber, classroom.NumberOfTeacher);
        }