Exemplo n.º 1
0
        public void TestFirstQuestion()
        {
            IDataSource      dataSource = new DataSource.DataSource(BuildStaticDoughnutTree());
            IDecisionService _service   = new DecisionService(dataSource);

            Assert.Equal(dataSource.DecisionTree.Statement, _service.GetFirstQuestion());
            //Assert.(3, _service.GetTreeMaxpath());
        }
Exemplo n.º 2
0
        public void TestNullDatasourceHandeler()
        {
            IDataSource      dataSource = new DataSource.DataSource(null);
            IDecisionService service    = new DecisionService(dataSource);

            Assert.Throws <NodeNotFoundException>(() => service.GetFirstQuestion());
            Assert.Throws <NodeNotFoundException>(() => service.GetFirstNode());
            Assert.Null(service.GetFullTree());
            //Assert.(3, _service.GetTreeMaxpath());
        }