GraphAware\Neo4j\Client\Tests\Issues\ReportedIssuesTest::testTryingToDeleteNodeWithRelsInTransactionShouldFailAndTxBeRolledBack PHP Method

testTryingToDeleteNodeWithRelsInTransactionShouldFailAndTxBeRolledBack() public method

    public function testTryingToDeleteNodeWithRelsInTransactionShouldFailAndTxBeRolledBack()
    {
        $this->emptyDb();
        $this->createNodeWithRels();
        $tx = $this->client->transaction();
        $tx->push('MATCH (n:Node) DELETE n');
        try {
            $tx->commit();
            // it should fail
            throw new RuntimeException();
        } catch (Neo4jException $e) {
            $this->assertTrue($tx->isRolledBack());
        }
    }