neoxygen / neo4j-neoclient

Simple PHP HttpClient for the Neo4j ReST API with Multi DB Support
MIT License
121 stars 138 forks source link

Fixes issues reported by Mulkave #13

Closed ikwattro closed 9 years ago

ikwattro commented 9 years ago
ikwattro commented 9 years ago

@Mulkave Please test this branch to see if it fits your needs ;-)

Mulkave commented 9 years ago

This test fails for me (used to pass):

$client = $this->getClient();
        $q = 'CREATE (u:`User` {name: {name}, email: {email}}) RETURN u';
        $params = ['name' => 'Abed Halawi', 'email' => 'halawi.abed@gmail.com'];
        $response = $client->sendCypherQuery($q, $params, null, array('graph'));

        $formatter = $this->getFormatter();
        $result = $formatter->format($response);
        $this->assertInstanceOf('Neoxygen\NeoClient\Formatter\Result', $result);
        // The user is getting created successfully but never returned afterwards.
        $this->assertArrayHasKey('User', $result->getNodes());

Any thoughts on this ?

ikwattro commented 9 years ago

Will test it

ikwattro commented 9 years ago

getNodes returns a collection of nodes, with numbers as keys