コード例 #1
0
        public void Add_Crew_With_NestedListOfStewardess_ReturnOk()
        {
            //Arrange
            var correctItem = new CrewDTO {
                PilotId = 1, StewardessesId = new List <int> {
                    1, 2
                }
            };
            //Act
            var result = _crewController.Post(correctItem).Result as StatusCodeResult;

            //Assert
            Assert.AreEqual(result.StatusCode, 200);
            //Reset
            _crewController.Delete(_context.Crews.Last().Id).Wait();
        }