Exemplo n.º 1
0
        public void ChangeData_should_changeName()
        {
            string newName;
            string nameOfClient;

            CreateObjects();
            newName = "Kate";
            clientManagement.ChangeData(0, 1, newName);
            nameOfClient = clientManagement.ShowClients[0].ClientName;
            Assert.AreEqual(newName, nameOfClient);
        }
Exemplo n.º 2
0
 public void ChangeClientData()
 {
     try
     {
         Console.WriteLine("Write client's index:");
         int index = Convert.ToInt32(Console.ReadLine());
         Console.WriteLine("Write 1 if you want to change name, 2 - surname, 3 - wanted type of realty, 4 - wanted cost of realty, 5 - bank account:");
         int field = Convert.ToInt32(Console.ReadLine());
         Console.WriteLine("Write new data:");
         string newData = Console.ReadLine();
         clientManagement.ChangeData(index, field, newData);
     }
     catch
     {
         Console.WriteLine("Incorrect input!!!");
         Console.WriteLine("Try again");
     }
 }