Beispiel #1
0
 public void AddPtrTest()
 {
     var p = new Param();
     p.MbrParam = "A";
     p.MbrData = "B";
     var aP = new ParamArray();
     aP.AddPtr(p);
     Assert.AreEqual(1, aP.Count());
     Assert.AreEqual("A", aP.GetCurrent().MbrParam);
     Assert.AreEqual("B", aP.GetCurrent().MbrData);
 }
Beispiel #2
0
 public void SearchTest()
 {
     var aP = new ParamArray();
     aP.AddRecord(new Param());
     aP.GetCurrent().MbrParam = ("A");
     aP.GetCurrent().MbrData = ("B");
     aP.AddRecord(new Param());
     aP.GetCurrent().MbrParam = ("C");
     aP.GetCurrent().MbrData = ("D");
     aP.AddRecord(new Param());
     aP.GetCurrent().MbrParam = ("E");
     aP.GetCurrent().MbrData = ("F");
     Assert.AreEqual("D", aP.Search("C"));
 }