private void TestCIsReturnedOnDepthTwo(TraversalDescription description)
 {
     using (Transaction transaction = BeginTx())
     {
         description = description.Expand(PathExpanders.forTypeAndDirection(_one, OUTGOING));
         int i = 0;
         foreach (Path position in description.Traverse(Node("A")))
         {
             assertEquals(i++, position.Length());
         }
     }
 }
예제 #2
0
//JAVA TO C# CONVERTER TODO TASK: Most Java annotations will not have direct .NET equivalent attributes:
//ORIGINAL LINE: @Test public void pathWithConstantDirection()
        public virtual void PathWithConstantDirection()
        {
            Node l = GetNodeWithName("l");

            ExpectPaths(GraphDb.traversalDescription().expand(PathExpanders.forConstantDirectionWithTypes(Types.A)).traverse(l), "l", "l,m", "l,m,n");

            Node n = GetNodeWithName("n");

            ExpectPaths(GraphDb.traversalDescription().expand(PathExpanders.forConstantDirectionWithTypes(Types.A)).traverse(n), "n", "n,m", "n,m,l", "n,o");

            Node q = GetNodeWithName("q");

            ExpectPaths(GraphDb.traversalDescription().expand(PathExpanders.forConstantDirectionWithTypes(Types.B)).traverse(q), "q", "q,p", "q,p,o");
        }
예제 #3
0
//JAVA TO C# CONVERTER TODO TASK: Most Java annotations will not have direct .NET equivalent attributes:
//ORIGINAL LINE: @Test public void canCreateExpanderWithMultipleTypesAndDirections()
        public virtual void CanCreateExpanderWithMultipleTypesAndDirections()
        {
            assertNotNull(PathExpanders.forTypesAndDirections(_t1, INCOMING, _t2, OUTGOING, _t3, BOTH));
        }