public void testAddCustomer() { //create new customer collection clsCustomerCollection customerList = new clsCustomerCollection(); //clear collection customerList.clear(); //add 2 test customers clsCustomer tstCustomer1 = new clsCustomer(); tstCustomer1.cusName = "Tester1"; clsCustomer tstCustomer2 = new clsCustomer(); tstCustomer2.cusName = "Tester2"; //create new test list List <clsCustomer> tstList = new List <clsCustomer>(); //add 2 test customers to test list and customerList tstList.Add(tstCustomer1); tstList.Add(tstCustomer2); customerList.add(tstCustomer1); customerList.add(tstCustomer2); //compare Assert.AreEqual(customerList.customerAtIndex(1), tstList[1]); }