예제 #1
0
        public void RemoveOrderTest()
        {
            if (order1 == null)
            {
                ClientAddOrderTest();
            }

            ManagerLogInTest();

            bool result = managerDataAccess.RemoveOrder(managerContext1.Id, order1.Id);

            Assert.IsTrue(result);

            var orders = managerDataAccess.GetOrders(managerContext1.Id);

            if (orders != null && orders.Any())
            {
                var removedOrder = orders.FirstOrDefault(o => o.Id == order1.Id);
                Assert.IsNull(removedOrder);
            }

            ManagerLogOutTest();
        }