コード例 #1
0
 public void TestRegistryClient()
 {
     //Arange
     work.RegistryClient("Log", "0000", 10);
     //Act
     BLL.Managment.ClientsManagment clients = new BLL.Managment.ClientsManagment();
     clients.SaveChanges();
     clients.Load();
     // Assert
     Assert.AreEqual("Log", clients.GetList().ElementAt(clients.GetList().Count - 1).Email);
 }
コード例 #2
0
        public void TestRemoveClient()
        {
            //Arange
            BLL.Managment.ClientsManagment clients = new BLL.Managment.ClientsManagment();
            Client cli = new Client("Oksi", "Buba", 1073);

            clients.Insert(cli);
            clients.SaveChanges();
            clients.Load();
            //Act
            clients.Delete(cli);
            // Assert
            if (clients.GetList().Count != 0)
            {
                Assert.AreNotEqual(cli, clients.GetList().ElementAt(clients.GetList().Count - 1));
            }
        }