Пример #1
0
        private void AddOrUpdateCustomerTest()
        {
            var customers = _test.GetCustomersByFirstName("李");

            foreach (var c in customers)
            {
                c.LastName = "Jianlong";
            }
            var c1 = new Customer {
                FirstName = "Jackie", LastName = "Jianlong"
            };
            var c2 = new Customer {
                FirstName = "Jackie", LastName = "Jianlong"
            };

            customers.Add(c1);
            customers.Add(c2);
            _testAUD.AddOrUpdateCustomer(customers);
            "==>AddOrUpdateCustomerTest:".Output(customers);
            "========================".Output();
            var list = _test.GetCustomersByFirstName("Jackie");

            "==>Jackie first names:".Output(list);
        }
Пример #2
0
        public void SaveOrUpdateCustomersTransactionTest()
        {
            var customers = _test.GetCustomersByFirstName("李");

            foreach (var c in customers)
            {
                c.LastName = "Jianlong2";
            }
            var c1 = new Customer {
                FirstName = "Jackie55", LastName = "Lee"
            };

            customers.Add(c1);
            _testTrans.SaveOrUpdateCustomersTransaction(customers);
            "==>SaveOrUpdateCustomersTransactionTest:".Output();
        }