public void TableProvider_EvaluateForeignKey() { var dmp = new MyDataModelProvider(); var tp = new MyTableProvider(dmp); tp.EvaluateForeignKey(null, String.Empty); }
public void TableProvider_EvaluateForeignKey_3() { var dmp = new MyDataModelProvider(); var tp = new MyTableProvider(dmp); var row = new MyRow(); tp.EvaluateForeignKey(row, "BogusName"); }
public void TableProvider_EvaluateForeignKey_2() { var dmp = new MyDataModelProvider(); var tp = new MyTableProvider(dmp); var row = new MyRow(); tp.EvaluateForeignKey(row, String.Empty); }
public void TableProvider_ToString() { var dmp = new MyDataModelProvider(); var tp = new MyTableProvider(dmp); tp.SetName("MyName"); Assert.AreEqual(tp.Name, tp.ToString(), "#A1"); }
public void TableProvider_Defaults() { var dmp = new MyDataModelProvider(); var tp = new MyTableProvider(dmp); Assert.IsTrue(tp.DataModel != null, "#A1"); Assert.AreEqual(typeof(MyDataModelProvider), tp.DataModel.GetType(), "#A2"); Assert.AreEqual(null, tp.EntityType, "#A3"); Assert.AreEqual(null, tp.Name, "#A4"); Assert.AreEqual(tp.GetType().ToString(), tp.ToString(), "#A5"); }
public void TableProvider_EvaluateForeignKey_4() { var dmp = new MyDataModelProvider(); var tp = new MyTableProvider(dmp); var row = new MyRow(); object o = tp.EvaluateForeignKey(row, "ForeignKey"); Assert.IsNotNull(o, "#A1"); Assert.IsTrue(o is string, "#A2"); Assert.AreEqual("Something", (string)o, "#A3"); o = tp.EvaluateForeignKey(row, "AnotherForeignKey"); Assert.IsNotNull(o, "#B1"); Assert.IsTrue(o is int, "#B2"); Assert.AreEqual(1, (int)o, "#B3"); }
public void TableProvider_Constructor() { var tp = new MyTableProvider(null); Assert.AreEqual(null, tp.DataModel, "#A1"); }
public void TableProvider_ToString() { var dmp = new MyDataModelProvider(); var tp = new MyTableProvider(dmp); tp.SetName ("MyName"); Assert.AreEqual(tp.Name, tp.ToString(), "#A1"); }
public void TableProvider_Defaults() { var dmp = new MyDataModelProvider(); var tp = new MyTableProvider(dmp); Assert.IsTrue(tp.DataModel != null, "#A1"); Assert.AreEqual(typeof (MyDataModelProvider), tp.DataModel.GetType (), "#A2"); Assert.AreEqual(null, tp.EntityType, "#A3"); Assert.AreEqual(null, tp.Name, "#A4"); Assert.AreEqual(tp.GetType ().ToString (), tp.ToString(), "#A5"); }