public void Sort_shouldReturn_SortedbyNameList() { ClientManagement sortedList = new ClientManagement(); CreateObjects(); sortedList.ShowClients = clientManagement.Sort(1); Assert.IsTrue(sortedList.ShowClients[0] == client3 && sortedList.ShowClients[1] == client1 && sortedList.ShowClients[2] == client2); }
public void ShowAllClients() { List <Client> result = new List <Client>(); Console.WriteLine("Choose type of sorting: 1 - by name of client, 2 - by surname of client, 3 - by banking account"); int type = Convert.ToInt32(Console.ReadLine()); result = clientManagement.Sort(type); foreach (Client client in result) { Console.WriteLine(client.ToString()); } }