public void TestDelete() { PatientBusinessLayer businessLayer = new PatientBusinessLayer(); Patient testPatient = businessLayer.GetPatientByEmail("*****@*****.**"); businessLayer.RemovePatient(testPatient); Assert.IsTrue(businessLayer.GetPatientByEmail("*****@*****.**") == null); }
public void TestEditDetails() { PatientBusinessLayer businessLayer = new PatientBusinessLayer(); Patient patient = businessLayer.GetPatientByEmail("*****@*****.**"); patient.PatientUser.Name = "TestEdit"; patient.EmergengyContactName = "TestMother"; businessLayer.UpdatePatientDetials(patient); Assert.AreEqual("TestEdit", businessLayer.GetPatientNameById(patient.Id)); Assert.AreEqual("TestMother", businessLayer.GetPatientById(patient.Id).EmergengyContactName); }