Exemple #1
0
def test_execute_gremlin_dsl(mocker):
    """Test the function get_version_information."""
    mocker.return_value = ""
    query_str = "g.V().has('ecosystem', eco).has('name',pkg).valueMap()"
    payload = {
        'gremlin': query_str,
        'bindings': {
            'eco': 'maven',
            'pkg': 'io.vertx:vertx-web'
        }
    }
    out = execute_gremlin_dsl(payload)
    assert out is None
Exemple #2
0
def test_execute_gremlin_dsl(_mock1):
    """Test error response for gremlin."""
    payload = {'gremlin': ''}
    result = execute_gremlin_dsl(url=GREMLIN_SERVER_URL_REST, payload=payload)
    assert result is None