public void TestForMkey() { DbEntry.Create(typeof(Mkey)); var p1 = new Mkey { FirstName = "test", LastName = "next", Age = 11 }; DbEntry.Insert(p1); var p2 = DbEntry.From<Mkey>().Where(p => p.FirstName == "test" && p.LastName == "next").Select()[0]; Assert.AreEqual(11, p2.Age); p2.Age = 18; DbEntry.Update(p2); var p3 = DbEntry.From<Mkey>().Where(p => p.FirstName == "test" && p.LastName == "next").Select()[0]; Assert.AreEqual(18, p3.Age); }
public void TestForMkey() { DbEntry.Create(typeof(Mkey)); var p1 = new Mkey { FirstName = "test", LastName = "next", Age = 11 }; DbEntry.Insert(p1); var p2 = DbEntry.From <Mkey>().Where(p => p.FirstName == "test" && p.LastName == "next").Select()[0]; Assert.AreEqual(11, p2.Age); p2.Age = 18; DbEntry.Update(p2); var p3 = DbEntry.From <Mkey>().Where(p => p.FirstName == "test" && p.LastName == "next").Select()[0]; Assert.AreEqual(18, p3.Age); }