Ejemplo n.º 1
0
        public void CreateDestinationNodeShouldThrowExceptionIfHasInvalidItems()
        {
            var obj = new ExpressionNodeFactory();
            var objects = new List<IExpressionObjectBase>
                              {
                                  new FunctionExpression()
                              };

            obj.CreateDestinationNode(objects, "Node");
        }
Ejemplo n.º 2
0
        public void CreateDestinationNodeShouldReturnDestinationNode()
        {
            var obj = new ExpressionNodeFactory();

            var destination = new DestinationFieldList { UniqueName = "Destination" };
            destination.Fields.Add(new DestinationField(destination));
            var source = new ConstantExpression();
            var connection = new Connection { Source = source.ConnectorOut, Sink = destination.Fields[0].ConnectorIn };

            var objects = new List<IExpressionObjectBase>
                              {   
                                  source,
                                  destination,
                                  connection
                              };

            Assert.IsNotNull(obj.CreateDestinationNode(objects, "Destination"));
        }