/** * Tests whether creating an existing node returns the instance of that node */ public function testCreateExistingNode() { $node1 = $this->graph->getNode('http://example.com/node/1'); $nodeType = $this->graph->getNode('http://vocab.com/type/node'); $this->assertSame($node1, $this->graph->createNode('http://example.com/node/1')); $this->assertSame($nodeType, $this->graph->createNode('http://vocab.com/type/node')); }