//JAVA TO C# CONVERTER TODO TASK: Most Java annotations will not have direct .NET equivalent attributes:
//ORIGINAL LINE: @Test public void shouldHandleSingleNodePath()
        public virtual void ShouldHandleSingleNodePath()
        {
            // Given
            Node node;

            using (Transaction tx = Db.beginTx())
            {
                node = Db.createNode();
                tx.Success();
            }

            // When
            Path mapped = _mapper.mapPath(path(AsNodeValues(node), AsRelationshipsValues()));

            // Then
            using (Transaction ignore = Db.beginTx())
            {
                assertThat(mapped.Length(), equalTo(0));
                assertThat(mapped.StartNode(), equalTo(node));
                assertThat(mapped.EndNode(), equalTo(node));
                assertThat(Iterables.asList(mapped.Relationships()), hasSize(0));
                assertThat(Iterables.asList(mapped.ReverseRelationships()), hasSize(0));
                assertThat(Iterables.asList(mapped.Nodes()), equalTo(singletonList(node)));
                assertThat(Iterables.asList(mapped.ReverseNodes()), equalTo(singletonList(node)));
                assertThat(mapped.LastRelationship(), nullValue());
                assertThat(Iterators.asList(mapped.GetEnumerator()), equalTo(singletonList(node)));
            }
        }
//JAVA TO C# CONVERTER TODO TASK: Most Java annotations will not have direct .NET equivalent attributes:
//ORIGINAL LINE: @Test public void shouldHandleSingleRelationshipPath()
        public virtual void ShouldHandleSingleRelationshipPath()
        {
            // Given
            Node         start, end;
            Relationship relationship;

            using (Transaction tx = Db.beginTx())
            {
                start        = Db.createNode();
                end          = Db.createNode();
                relationship = start.CreateRelationshipTo(end, RelationshipType.withName("R"));
                tx.Success();
            }

            // When
            Path mapped = _mapper.mapPath(path(AsNodeValues(start, end), AsRelationshipsValues(relationship)));

            // Then
            using (Transaction ignore = Db.beginTx())
            {
                assertThat(mapped.Length(), equalTo(1));
                assertThat(mapped.StartNode(), equalTo(start));
                assertThat(mapped.EndNode(), equalTo(end));
                assertThat(Iterables.asList(mapped.Relationships()), equalTo(singletonList(relationship)));
                assertThat(Iterables.asList(mapped.ReverseRelationships()), equalTo(singletonList(relationship)));
                assertThat(Iterables.asList(mapped.Nodes()), equalTo(Arrays.asList(start, end)));
                assertThat(Iterables.asList(mapped.ReverseNodes()), equalTo(Arrays.asList(end, start)));
                assertThat(mapped.LastRelationship(), equalTo(relationship));
                assertThat(Iterators.asList(mapped.GetEnumerator()), equalTo(Arrays.asList(start, relationship, end)));
            }
        }
//JAVA TO C# CONVERTER TODO TASK: Most Java annotations will not have direct .NET equivalent attributes:
//ORIGINAL LINE: @Test public void shouldHandleLongPath()
        public virtual void ShouldHandleLongPath()
        {
            // Given
            Node         a, b, c, d, e;
            Relationship r1, r2, r3, r4;

            using (Transaction tx = Db.beginTx())
            {
                a  = Db.createNode();
                b  = Db.createNode();
                c  = Db.createNode();
                d  = Db.createNode();
                e  = Db.createNode();
                r1 = a.CreateRelationshipTo(b, RelationshipType.withName("R"));
                r2 = b.CreateRelationshipTo(c, RelationshipType.withName("R"));
                r3 = c.CreateRelationshipTo(d, RelationshipType.withName("R"));
                r4 = d.CreateRelationshipTo(e, RelationshipType.withName("R"));
                tx.Success();
            }

            // When
            Path mapped = _mapper.mapPath(path(AsNodeValues(a, b, c, d, e), AsRelationshipsValues(r1, r2, r3, r4)));

            // Then
            using (Transaction ignore = Db.beginTx())
            {
                assertThat(mapped.Length(), equalTo(4));
                assertThat(mapped.StartNode(), equalTo(a));
                assertThat(mapped.EndNode(), equalTo(e));
                assertThat(Iterables.asList(mapped.Relationships()), equalTo(Arrays.asList(r1, r2, r3, r4)));
                assertThat(Iterables.asList(mapped.ReverseRelationships()), equalTo(Arrays.asList(r4, r3, r2, r1)));
                assertThat(Iterables.asList(mapped.Nodes()), equalTo(Arrays.asList(a, b, c, d, e)));
                assertThat(Iterables.asList(mapped.ReverseNodes()), equalTo(Arrays.asList(e, d, c, b, a)));
                assertThat(mapped.LastRelationship(), equalTo(r4));
                assertThat(Iterators.asList(mapped.GetEnumerator()), equalTo(Arrays.asList(a, r1, b, r2, c, r3, d, r4, e)));
            }
        }