<commit_before><?php

namespace GraphAware\Bolt\Tests\Integration;

use GraphAware\Bolt\Driver;
use Neoxygen\NeoClient\ClientBuilder;

abstract class IntegrationTestCase extends \PHPUnit_Framework_TestCase
{
    /**
     * @var \GraphAware\Bolt\Driver
     */
    protected $driver;

    /**
     * @var \Neoxygen\NeoClient\Client
     */
    protected $client;

    public function setUp()
    {
        $this->driver = new Driver('localhost', 7687);
        $this->client = ClientBuilder::create()
            ->addConnection('default', 'http', 'localhost', 7474)
            ->setAutoFormatResponse(true)
            ->build();
    }

    /**
     * @return \GraphAware\Bolt\Driver
     */
    public function getDriver()
    {
        return $this->driver;
    }

    /**
     * @return \Neoxygen\NeoClient\Client
     */
    public function getClient()
    {
        return $this->client;
    }

    public function emptyDB()
    {
        $q = 'MATCH (n) OPTIONAL MATCH (n)-[r]-() DELETE r,n';
        $this->client->sendCypherQuery($q);
    }
}<commit_msg>increased timeout for delete on travis<commit_after><?php

namespace GraphAware\Bolt\Tests\Integration;

use GraphAware\Bolt\Driver;
use Neoxygen\NeoClient\ClientBuilder;

abstract class IntegrationTestCase extends \PHPUnit_Framework_TestCase
{
    /**
     * @var \GraphAware\Bolt\Driver
     */
    protected $driver;

    /**
     * @var \Neoxygen\NeoClient\Client
     */
    protected $client;

    public function setUp()
    {
        $this->driver = new Driver('localhost', 7687);
        $this->client = ClientBuilder::create()
            ->addConnection('default', 'http', 'localhost', 7474)
            ->setAutoFormatResponse(true)
            ->setDefaultTimeout(20)
            ->build();
    }

    /**
     * @return \GraphAware\Bolt\Driver
     */
    public function getDriver()
    {
        return $this->driver;
    }

    /**
     * @return \Neoxygen\NeoClient\Client
     */
    public function getClient()
    {
        return $this->client;
    }

    public function emptyDB()
    {
        $q = 'MATCH (n) DETACH DELETE n';
        $this->client->sendCypherQuery($q);
    }
}
{'fraction_non_alphanumeric': 0.1371191135734072, 'fraction_numerical': 0.008310249307479225, 'mean_word_length': 2.224702380952381, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 22, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '1447319', 'n_tokens_mistral': 697, 'n_tokens_neox': 661, 'n_words': 126}