Skip to content

TraversalSpec should return VertexNameSpec when property or method is missing #87

@moaxcp

Description

@moaxcp

Problem

When traversals are used outside of the dsl it would be nice if they acted as expected when using a VertexNameSpec.

Test

The following test sets root to A. If the call to A created a VertexNameSpec.

given:
def names = []
graph.breadthFirstTraversal {
    root A
    visit { vertex ->
        names << vertex.name
    }
}

expect:
names == ['A', 'B', 'D', 'E', 'C']

Tasks

Add propertyMissing to TraversalSpec which returns a VertexNameSpec. Add appropriate tests to 'nondsl' test package.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions