public void DirtyWhereCostruction() { // This way, to construct the where clause, can be useful if // you don't know which will be the first expression Where w = new Where(); w.And("f.Name like :p1").And("length(f.Name)>2").Or("f.Name like 'N%'"); Assert.AreEqual("where ((f.Name like :p1) and (length(f.Name)>2) or (f.Name like 'N%'))", w.Clause); w = new Where(); w.Or("f.Name like :p1").And("length(f.Name)>2").Or("f.Name like 'N%'"); Assert.AreEqual("where ((f.Name like :p1) and (length(f.Name)>2) or (f.Name like 'N%'))", w.Clause); }