Jyxo\Beholder\TestCase\PgsqlTest::getPgsql PHP Method

getPgsql() private method

Returns connection settings.
private getPgsql ( ) : array
return array
    private function getPgsql() : array
    {
        // Skips the test if no PostgreSQL connection is defined
        if (empty($GLOBALS['pgsql']) || !preg_match('~^([^:]+):([^@]+)@([^:]+):(\\d+)/(\\w+)$~', $GLOBALS['pgsql'], $matches)) {
            $this->markTestSkipped('PostgreSQL not set');
        }
        return ['user' => $matches[1], 'password' => $matches[2], 'host' => $matches[3], 'port' => $matches[4], 'database' => $matches[5]];
    }