public void Text_ExpectInvalid() { //arrange Repairbook RepairTest = new Repairbook(); RepairTest.Plate = v_Plate; RepairTest.Text = ""; //act RepairTest.SaveToDb(DB); //assert //should handle with ArgumentException }
public void Price_ExceptInvalid() { //arrange Repairbook RepairTest = new Repairbook(); RepairTest.Plate = v_Plate; RepairTest.Text = v_Text; RepairTest.Price = -1; //act RepairTest.SaveToDb(DB); //assert //should handle with ArgumentOutOfRangeException }
public void SaveToDb_ExpectValid() { //arrange Repairbook RepairTest = new Repairbook(); RepairTest.Plate = v_Plate; RepairTest.Text = v_Text; RepairTest.Price = v_Price; //act RepairTest.SaveToDb(DB); //assert //should handle with no exceptions }