public void CreateForSql_StructWithoutCast_ThrowsInvalidCastException() { var act = Assert.Throws <InvalidCastException>(() => { var val = new StructWithoutRequiredCast("test"); SvoParameter.CreateForSql("par", val); }); Assert.AreEqual("Cast from Qowaiv.UnitTests.Data.StructWithoutRequiredCast to System.String is not valid.", act.Message); }
public void CreateForSql_StructWithoutCast_ThrowsInvalidCastException() { var act = Assert.Throws<InvalidCastException>(() => { var val = new StructWithoutRequiredCast("test"); SvoParameter.CreateForSql("par", val); }); Assert.AreEqual("Cast from Qowaiv.UnitTests.Data.StructWithoutRequiredCast to System.String is not valid.", act.Message); }