public void Delete_NonExistantId_0() { //Assemble ClassTable classTable = new ClassTable(); int expected = 0; //Act classTable.delete(0); int actual = classTable.count(); //Assert Assert.AreEqual(expected, actual); }
public void Delete_CreatedDeleteAndCount1Record_0() { //Assemble ClassModel classModel = new ClassModel(); classModel.programId = programId; classModel.staffId = staffId; classModel.classDate = new DateTime(2021, 10, 03); classModel.startTime = new TimeSpan(2, 33, 0); classModel.endTime = new TimeSpan(3, 33, 0); int expected = 0; ClassTable classTable = new ClassTable(); int classID = classTable.create(classModel); //Act classTable.delete(classID); int actual = classTable.count(); //Assert Assert.AreEqual(expected, actual); }