Example #1
0
        protected void Resolve()
        {
            if (resolved || resolving)
            {
                return;
            }

            resolving = true;

            ResolveMembers();

            TestPathTree parentTree = null;

            if (Parent != null)
            {
                parentTree = Parent.Tree;
            }

            children = CreateChildren().ToList();

            host = CreateHost();

            var parameterHosts = new LinkedList <TestHost> ();

            tree = treeRoot = new TestPathTree(this, host, parentTree);

            foreach (var current in CreateParameterHosts())
            {
                parameterHosts.AddFirst(current);
            }

            var parameterIter = parameterHosts.Last;

            while (parameterIter != null)
            {
                tree          = tree.Add(parameterIter.Value);
                parameterIter = parameterIter.Previous;
            }

            resolvedTree = true;

            foreach (var child in children)
            {
                child.Resolve();
            }

            resolvedChildren = true;

            resolved = true;
        }
 public TestBuilderInvoker(TestBuilderHost host, TestNode node, TestInvoker inner)
 {
     Host  = host;
     Node  = node;
     Inner = inner;
 }
Example #3
0
 public TestBuilderInstance(TestBuilderHost host, TestPath path, TestInstance parent)
     : base(host, path, parent)
 {
     Builder = host.Builder;
 }
Example #4
0
 public TestBuilderInvoker(TestBuilderHost host, TestPath path, TestInvoker inner)
 {
     Host  = host;
     Path  = path;
     Inner = inner;
 }
 public TestBuilderInstance(TestBuilderHost host, TestNode node, TestInstance parent)
     : base(host, node, parent)
 {
     Builder = host.Builder;
     Value   = new TestBuilderValue(this);
 }