public void testDLTestMatchFailsOnMismatchedExample() { DataSet ds = DataSetFactory.getRestaurantDataSet(); Example e = ds.getExample(0); tvn.cosine.ai.learning.inductive.DecisionListTest test = new tvn.cosine.ai.learning.inductive.DecisionListTest(); test.add("type", "Thai"); Assert.IsFalse(test.matches(e)); }
public void testDLTestMatchSucceedsWithMatchedExample() { DataSet ds = DataSetFactory.getRestaurantDataSet(); Example e = ds.getExample(0); tvn.cosine.ai.learning.inductive.DecisionListTest test = new tvn.cosine.ai.learning.inductive.DecisionListTest(); test.add("type", "French"); Assert.IsTrue(test.matches(e)); }