diff --git a/.tests/lib/BaseDatabaseTestCase.php b/.tests/lib/BaseDatabaseTestCase.php index dbdfd33..71a1810 100644 --- a/.tests/lib/BaseDatabaseTestCase.php +++ b/.tests/lib/BaseDatabaseTestCase.php @@ -1,16 +1,19 @@ mockConfig = new uConfig(false); } - public static function setUpBeforeClass() { + public static function setUpBeforeClass(): void { if (file_exists(__DIR__ . '/../.env')) { - $dotenv = Dotenv\Dotenv::create(__DIR__ . '/..'); + $dotenv = Dotenv\Dotenv::createImmutable(__DIR__ . '/..'); $dotenv->load(); $dotenv->required(['DB_DSN', 'DB_USER', 'DB_PASS']); } - $db_dsn = getenv('DB_DSN'); - $db_user = getenv('DB_USER'); - $db_pass = getenv('DB_PASS'); + $db_dsn = $_ENV['DB_DSN']; + $db_user = $_ENV['DB_USER']; + $db_pass = $_ENV['DB_PASS']; // pdo connection if (self::$pdo == null) { @@ -68,7 +71,7 @@ abstract class BaseDatabaseTestCase extends PHPUnit_Extensions_Database_TestCase } } - public static function tearDownAfterClass() { + public static function tearDownAfterClass(): void { self::$pdo = null; } @@ -76,9 +79,9 @@ abstract class BaseDatabaseTestCase extends PHPUnit_Extensions_Database_TestCase * Set up database connection * This will also override uDb class connection * - * @return PHPUnit_Extensions_Database_DB_IDatabaseConnection + * @return Connection */ - public function getConnection() { + public function getConnection(): Connection { if ($this->conn === null) { $this->conn = $this->createDefaultDBConnection(self::$pdo, getenv('DB_NAME')); } @@ -88,14 +91,14 @@ abstract class BaseDatabaseTestCase extends PHPUnit_Extensions_Database_TestCase /** * Create data set from xml fixture * - * @return PHPUnit_Extensions_Database_DataSet_IDataSet + * @return PHPUnit\DbUnit\DataSet\IDataSet */ - protected function getDataSet() { + protected function getDataSet(): IDataSet { $this->resetAutoincrement(); return $this->createFlatXMLDataSet(__DIR__ . '/../fixtures/fixture_empty.xml'); } - protected function resetAutoincrement($users = 1, $tracks = 1, $positions = 1, $layers = 1) { + protected function resetAutoincrement($users = 1, $tracks = 1, $positions = 1, $layers = 1): void { if (self::$driver === "pgsql") { self::$pdo->exec("ALTER SEQUENCE IF EXISTS users_id_seq RESTART WITH $users"); self::$pdo->exec("ALTER SEQUENCE IF EXISTS tracks_id_seq RESTART WITH $tracks"); @@ -125,7 +128,7 @@ abstract class BaseDatabaseTestCase extends PHPUnit_Extensions_Database_TestCase * Reset connection * Fixes sqlite error when db schema changes in another connection. */ - protected function resetConnection() { + protected function resetConnection(): void { $this->closeConnection($this->conn); $this->conn = null; self::tearDownAfterClass(); @@ -139,7 +142,7 @@ abstract class BaseDatabaseTestCase extends PHPUnit_Extensions_Database_TestCase * @param array $rowsArr Array of rows * @return int|null Last insert id if available, NULL otherwise */ - private function pdoInsert($table, $rowsArr = []) { + private function pdoInsert(string $table, array $rowsArr = []): ?int { $ret = NULL; if (!empty($rowsArr)) { $values = ':' . implode(', :', array_keys($rowsArr)); @@ -160,8 +163,8 @@ abstract class BaseDatabaseTestCase extends PHPUnit_Extensions_Database_TestCase * @param string $query Insert query * @return int|null Last insert id if available, NULL otherwise */ - private function pdoInsertRaw($query) { - $ret = NULL; + private function pdoInsertRaw(string $query): ?int { + $ret = null; if (self::$pdo->exec($query) !== false) { $ret = self::$pdo->lastInsertId(); } @@ -175,7 +178,7 @@ abstract class BaseDatabaseTestCase extends PHPUnit_Extensions_Database_TestCase * @param int $columnNumber Optional column number (default is first column) * @return string|bool Column or false if no data */ - protected function pdoGetColumn($query, $columnNumber = 0) { + protected function pdoGetColumn(string $query, int $columnNumber = 0) { $column = false; $stmt = self::$pdo->query($query); if ($stmt !== false) { @@ -189,12 +192,12 @@ abstract class BaseDatabaseTestCase extends PHPUnit_Extensions_Database_TestCase * Insert user data to database * If parameters are omitted they default test values are used * - * @param string $user User login - * @param string $pass User password + * @param string|null $user User login + * @param string|null $pass User password * @param bool $isAdmin User is admin * @return int|bool User id or false on error */ - protected function addTestUser($user = NULL, $pass = NULL, $isAdmin = false) { + protected function addTestUser(?string $user = null, ?string $pass = null, bool $isAdmin = false) { if (is_null($user)) { $user = $this->testUser; } if (is_null($pass)) { $pass = $this->testPass; } $id = $this->pdoInsert('users', [ 'login' => $user, 'password' => $pass, 'admin' => (int) $isAdmin ]); @@ -208,12 +211,12 @@ abstract class BaseDatabaseTestCase extends PHPUnit_Extensions_Database_TestCase * Insert track data to database. * If parameters are omitted they default test values are used * - * @param int $userId Optional track id - * @param string $trackName Optional track name - * @param string $comment Optional comment + * @param int|null $userId Optional track id + * @param string|null $trackName Optional track name + * @param string|null $comment Optional comment * @return int|bool Track id or false on error */ - protected function addTestTrack($userId = NULL, $trackName = NULL, $comment = NULL) { + protected function addTestTrack(?int $userId = null, ?string $trackName = null, ?string $comment = null) { if (is_null($userId)) { $userId = $this->testUserId; } if (is_null($trackName)) { $trackName = $this->testTrackName; } if (is_null($comment)) { $comment = $this->testTrackComment; } @@ -228,14 +231,14 @@ abstract class BaseDatabaseTestCase extends PHPUnit_Extensions_Database_TestCase * Insert position data to database * If parameters are omitted they default test values are used * - * @param int $userId - * @param int $trackId - * @param int $timeStamp - * @param double $latitude - * @param double $longitude - * @return int|bool Position id or false on error + * @param int|null $userId + * @param int|null $trackId + * @param int|null $timeStamp + * @param float|null $latitude + * @param float|null $longitude + * @return int|null Position id or false on error */ - protected function addTestPosition($userId = NULL, $trackId = NULL, $timeStamp = NULL, $latitude = NULL, $longitude = NULL) { + protected function addTestPosition(?int $userId = null, ?int $trackId = null, ?int $timeStamp = null, ?float $latitude = null, ?float $longitude = null): ?int { if (is_null($userId)) { $userId = $this->testUserId; } if (is_null($trackId)) { $trackId = $this->testTrackId; } if (is_null($timeStamp)) { $timeStamp = $this->testTimestamp; } @@ -247,33 +250,27 @@ abstract class BaseDatabaseTestCase extends PHPUnit_Extensions_Database_TestCase return $this->pdoInsertRaw($query); } - public function unix_timestamp($column) { + public function unix_timestamp(string $column): string { switch (self::$driver) { default: case "mysql": return "UNIX_TIMESTAMP($column)"; - break; case "pgsql": return "EXTRACT(EPOCH FROM $column)"; - break; case "sqlite": return "STRFTIME('%s', $column)"; - break; } } - public function from_unixtime($column) { + public function from_unixtime(string $column): string { switch (self::$driver) { default: case "mysql": return "FROM_UNIXTIME($column)"; - break; case "pgsql": return "TO_TIMESTAMP($column)"; - break; case "sqlite": return "DATETIME($column, 'unixepoch')"; - break; } } } diff --git a/.tests/lib/UloggerAPITestCase.php b/.tests/lib/UloggerAPITestCase.php index 45eb67e..0f5d7c8 100644 --- a/.tests/lib/UloggerAPITestCase.php +++ b/.tests/lib/UloggerAPITestCase.php @@ -1,5 +1,7 @@ load(); $dotenv->required(['ULOGGER_URL']); } - $url = getenv('ULOGGER_URL'); + $url = $_ENV['ULOGGER_URL']; $this->http = new GuzzleHttp\Client([ 'base_uri' => $url, 'cookies' => true ]); } - public function tearDown() { + public function tearDown(): void { parent::tearDown(); $this->http = null; } - protected function getDataSet() { + protected function getDataSet(): IDataSet { $this->resetAutoincrement(2); return $this->createFlatXMLDataSet(__DIR__ . '/../fixtures/fixture_admin.xml'); } @@ -38,8 +40,9 @@ class UloggerAPITestCase extends BaseDatabaseTestCase { * @param string|null $user Login (defaults to test user) * @param string|null $pass Optional password (defaults to test password) * @return bool true on success, false otherwise + * @throws GuzzleException */ - public function authenticate($user = NULL, $pass = NULL) { + public function authenticate(?string $user = null, ?string $pass = null): bool { if (is_null($user)) { $user = $this->testAdminUser; } if (is_null($pass)) { $pass = $this->testAdminPass; } @@ -50,7 +53,7 @@ class UloggerAPITestCase extends BaseDatabaseTestCase { ]; $response = $this->http->post('/client/index.php', $options); - return ($response->getStatusCode() == 200); + return $response->getStatusCode() === 200; } } ?> diff --git a/.tests/lib/UloggerDatabaseTestCase.php b/.tests/lib/UloggerDatabaseTestCase.php index b18895c..c1b0c05 100644 --- a/.tests/lib/UloggerDatabaseTestCase.php +++ b/.tests/lib/UloggerDatabaseTestCase.php @@ -13,29 +13,29 @@ class UloggerDatabaseTestCase extends BaseDatabaseTestCase { /** * @throws ReflectionException */ - public static function setUpBeforeClass() { + public static function setUpBeforeClass(): void { parent::setUpBeforeClass(); if (file_exists(__DIR__ . '/../.env')) { - $dotenv = Dotenv\Dotenv::create(__DIR__ . '/..'); + $dotenv = Dotenv\Dotenv::createImmutable(__DIR__ . '/..'); $dotenv->load(); $dotenv->required(['DB_DSN', 'DB_USER', 'DB_PASS']); } - $db_dsn = getenv('DB_DSN'); - $db_user = getenv('DB_USER'); - $db_pass = getenv('DB_PASS'); + $db_dsn = $_ENV['DB_DSN']; + $db_user = $_ENV['DB_USER']; + $db_pass = $_ENV['DB_PASS']; // uDb connection if (self::$udb == null) { - self::$udb = new ReflectionClass("uDb"); + self::$udb = new ReflectionClass('uDb'); $dbInstance = self::$udb->getProperty('instance'); $dbInstance->setAccessible(true); $dbInstance->setValue(new uDb($db_dsn, $db_user, $db_pass)); } } - public static function tearDownAfterClass() { + public static function tearDownAfterClass(): void { parent::tearDownAfterClass(); self::$udb = null; } diff --git a/.tests/phpunit.xml b/.tests/phpunit.xml index 81a05b1..38a49c6 100644 --- a/.tests/phpunit.xml +++ b/.tests/phpunit.xml @@ -1,23 +1,24 @@ - - - - tests - - - - - .. - - ../.tests - ../vendor - - - - - - - - - + + + + .. + + + ../.tests + ../vendor + + + + + + + + tests + + + + + + diff --git a/.tests/tests/AuthTest.php b/.tests/tests/AuthTest.php index a96085b..27c9065 100644 --- a/.tests/tests/AuthTest.php +++ b/.tests/tests/AuthTest.php @@ -6,7 +6,7 @@ require_once(__DIR__ . "/../../helpers/config.php"); class AuthTest extends UloggerDatabaseTestCase { - public function setUp() { + public function setUp(): void { $_SESSION = []; parent::setUp(); } @@ -14,85 +14,85 @@ class AuthTest extends UloggerDatabaseTestCase { /** * @runInSeparateProcess */ - public function testLogin() { + public function testLogin(): void { $this->addTestUser($this->testUser, password_hash($this->testPass, PASSWORD_DEFAULT)); - $this->assertEquals(1, $this->getConnection()->getRowCount('users'), "Wrong row count"); + self::assertEquals(1, $this->getConnection()->getRowCount('users'), "Wrong row count"); $auth = new uAuth(); $auth->checkLogin($this->testUser, $this->testPass); - $this->assertTrue($auth->isAuthenticated(), "Not authenticated"); - $this->assertInstanceOf(uUser::class, $auth->user, "User variable not set"); - $this->assertEquals($this->testUser, $auth->user->login, "Wrong login"); - $this->assertEquals($_SESSION["user"]->login, $auth->user->login, "Wrong login"); - $this->assertInstanceOf(uUser::class, $_SESSION["user"], "User not set in session"); + self::assertTrue($auth->isAuthenticated(), "Not authenticated"); + self::assertInstanceOf(uUser::class, $auth->user, "User variable not set"); + self::assertEquals($this->testUser, $auth->user->login, "Wrong login"); + self::assertEquals($_SESSION["user"]->login, $auth->user->login, "Wrong login"); + self::assertInstanceOf(uUser::class, $_SESSION["user"], "User not set in session"); } /** * @runInSeparateProcess */ - public function testLoginBadPass() { + public function testLoginBadPass(): void { $this->addTestUser($this->testUser, password_hash($this->testPass, PASSWORD_DEFAULT)); - $this->assertEquals(1, $this->getConnection()->getRowCount('users'), "Wrong row count"); + self::assertEquals(1, $this->getConnection()->getRowCount('users'), "Wrong row count"); $auth = new uAuth(); $auth->checkLogin($this->testUser, "badPass"); - $this->assertFalse($auth->isAuthenticated(), "Should not be authenticated"); - $this->assertInternalType('null', $auth->user, "User not null"); + self::assertFalse($auth->isAuthenticated(), "Should not be authenticated"); + self::assertNull($auth->user, "User not null"); } /** * @runInSeparateProcess */ - public function testLoginEmptyLogin() { + public function testLoginEmptyLogin(): void { $this->addTestUser($this->testUser, password_hash($this->testPass, PASSWORD_DEFAULT)); - $this->assertEquals(1, $this->getConnection()->getRowCount('users'), "Wrong row count"); + self::assertEquals(1, $this->getConnection()->getRowCount('users'), "Wrong row count"); $auth = new uAuth(); $auth->checkLogin("", $this->testPass); - $this->assertFalse($auth->isAuthenticated(), "Should not be authenticated"); - $this->assertInternalType('null', $auth->user, "User not null"); + self::assertFalse($auth->isAuthenticated(), "Should not be authenticated"); + self::assertNull($auth->user, "User not null"); } /** * @runInSeparateProcess */ - public function testLoginNoFormData() { + public function testLoginNoFormData(): void { $this->addTestUser($this->testUser, password_hash($this->testPass, PASSWORD_DEFAULT)); - $this->assertEquals(1, $this->getConnection()->getRowCount('users'), "Wrong row count"); + self::assertEquals(1, $this->getConnection()->getRowCount('users'), "Wrong row count"); $auth = new uAuth(); - $this->assertFalse($auth->isAuthenticated(), "Should not be authenticated"); - $this->assertInternalType('null', $auth->user, "User not null"); + self::assertFalse($auth->isAuthenticated(), "Should not be authenticated"); + self::assertNull($auth->user, "User not null"); } /** * @runInSeparateProcess */ - public function testSessionAuth() { + public function testSessionAuth(): void { $this->addTestUser($this->testUser, password_hash($this->testPass, PASSWORD_DEFAULT)); - $this->assertEquals(1, $this->getConnection()->getRowCount('users'), "Wrong row count"); + self::assertEquals(1, $this->getConnection()->getRowCount('users'), "Wrong row count"); $user = new uUser($this->testUser); - $this->assertTrue($user->isValid, "User not valid"); + self::assertTrue($user->isValid, "User not valid"); session_name("ulogger"); session_start(); $_SESSION["user"] = $user; unset($user); @$auth = new uAuth(); - $this->assertTrue($auth->isAuthenticated(), "Should be authenticated"); - $this->assertEquals($this->testUser, $auth->user->login, "Wrong login"); + self::assertTrue($auth->isAuthenticated(), "Should be authenticated"); + self::assertEquals($this->testUser, $auth->user->login, "Wrong login"); } /** * @runInSeparateProcess */ - public function testSessionAndRequest() { + public function testSessionAndRequest(): void { $this->addTestUser($this->testUser, password_hash($this->testPass, PASSWORD_DEFAULT)); - $this->assertEquals(1, $this->getConnection()->getRowCount('users'), "Wrong row count"); + self::assertEquals(1, $this->getConnection()->getRowCount('users'), "Wrong row count"); $user = new uUser($this->testUser); - $this->assertTrue($user->isValid, "User not valid"); + self::assertTrue($user->isValid, "User not valid"); session_name("ulogger"); session_start(); $_SESSION["user"] = $user; @@ -100,35 +100,35 @@ class AuthTest extends UloggerDatabaseTestCase { @$auth = new uAuth(); $auth->checkLogin($this->testUser, $this->testPass); - $this->assertTrue($auth->isAuthenticated(), "Should be authenticated"); - $this->assertEquals($this->testUser, $auth->user->login, "Wrong login"); + self::assertTrue($auth->isAuthenticated(), "Should be authenticated"); + self::assertEquals($this->testUser, $auth->user->login, "Wrong login"); } /** * @runInSeparateProcess */ - public function testIsNotAdmin() { + public function testIsNotAdmin(): void { $this->addTestUser($this->testUser, password_hash($this->testPass, PASSWORD_DEFAULT)); - $this->assertEquals(1, $this->getConnection()->getRowCount('users'), "Wrong row count"); + self::assertEquals(1, $this->getConnection()->getRowCount('users'), "Wrong row count"); @$auth = new uAuth(); $auth->checkLogin($this->testUser, $this->testPass); - $this->assertTrue($auth->isAuthenticated(), "Should be authenticated"); - $this->assertFalse($auth->isAdmin(), "Should not be admin"); + self::assertTrue($auth->isAuthenticated(), "Should be authenticated"); + self::assertFalse($auth->isAdmin(), "Should not be admin"); } /** * @runInSeparateProcess */ - public function testIsAdmin() { + public function testIsAdmin(): void { $this->addTestUser($this->testUser, password_hash($this->testPass, PASSWORD_DEFAULT), true); - $this->assertEquals(1, $this->getConnection()->getRowCount('users'), "Wrong row count"); + self::assertEquals(1, $this->getConnection()->getRowCount('users'), "Wrong row count"); @$auth = new uAuth(); $auth->checkLogin($this->testUser, $this->testPass); - $this->assertTrue($auth->isAuthenticated(), "Should be authenticated"); - $this->assertTrue($auth->isAdmin(), "Should be admin"); + self::assertTrue($auth->isAuthenticated(), "Should be authenticated"); + self::assertTrue($auth->isAdmin(), "Should be admin"); } } diff --git a/.tests/tests/ClientAPITest.php b/.tests/tests/ClientAPITest.php index 390682f..f6f47d0 100644 --- a/.tests/tests/ClientAPITest.php +++ b/.tests/tests/ClientAPITest.php @@ -1,215 +1,253 @@ assertTrue($this->authenticate(), "Authentication failed"); + /** + * @throws GuzzleException + */ + public function testNoAction(): void { + self::assertTrue($this->authenticate(), "Authentication failed"); $options = [ 'http_errors' => false ]; $response = $this->http->post('/client/index.php', $options); - $this->assertEquals(200, $response->getStatusCode(), "Unexpected status code"); + self::assertEquals(200, $response->getStatusCode(), "Unexpected status code"); $json = json_decode((string) $response->getBody()); - $this->assertTrue($json->{'error'}, "Unexpected success"); + self::assertTrue($json->{'error'}, "Unexpected success"); } /* auth */ - public function testAuthOk() { + /** + * @throws GuzzleException + */ + public function testAuthOk(): void { $options = [ 'http_errors' => false, 'form_params' => [ 'action' => 'auth', 'user' => $this->testAdminUser, 'pass' => $this->testAdminPass ], ]; $response = $this->http->post('/client/index.php', $options); - $this->assertEquals(200, $response->getStatusCode(), "Unexpected status code"); + self::assertEquals(200, $response->getStatusCode(), "Unexpected status code"); $json = json_decode((string) $response->getBody()); - $this->assertFalse($json->{'error'}, "Unexpected error"); + self::assertFalse($json->{'error'}, "Unexpected error"); } - public function testAuthFail() { + /** + * @throws GuzzleException + */ + public function testAuthFail(): void { $options = [ 'http_errors' => false, 'form_params' => [ 'action' => 'adduser', 'user' => 'noexist', 'pass' => 'noexist' ], ]; $response = $this->http->post('/client/index.php', $options); - $this->assertEquals(401, $response->getStatusCode(), "Unexpected status code"); + self::assertEquals(401, $response->getStatusCode(), "Unexpected status code"); } /* adduser */ - - public function testAddUser() { - $this->assertTrue($this->authenticate(), "Authentication failed"); - $this->assertEquals(1, $this->getConnection()->getRowCount('users'), "Wrong row count"); + /** + * @throws GuzzleException + */ + public function testAddUser(): void { + self::assertTrue($this->authenticate(), "Authentication failed"); + self::assertEquals(1, $this->getConnection()->getRowCount('users'), "Wrong row count"); $options = [ 'http_errors' => false, 'form_params' => [ 'action' => 'adduser', 'login' => $this->testUser, 'password' => $this->testPass ], ]; $response = $this->http->post('/client/index.php', $options); - $this->assertEquals(200, $response->getStatusCode(), "Unexpected status code"); + self::assertEquals(200, $response->getStatusCode(), "Unexpected status code"); $json = json_decode((string) $response->getBody()); - $this->assertFalse($json->{'error'}, "Unexpected error"); - $this->assertEquals(2, $json->{'userid'}, "Wrong user id"); - $this->assertEquals(2, $this->getConnection()->getRowCount('users'), "Wrong row count"); + self::assertFalse($json->{'error'}, "Unexpected error"); + self::assertEquals(2, $json->{'userid'}, "Wrong user id"); + self::assertEquals(2, $this->getConnection()->getRowCount('users'), "Wrong row count"); $expected = [ "id" => 2, "login" => $this->testUser ]; $actual = $this->getConnection()->createQueryTable("users", "SELECT id, login FROM users"); $this->assertTableContains($expected, $actual, "Wrong actual table data"); } - public function testAddUserExistingLogin() { - $this->assertTrue($this->authenticate(), "Authentication failed"); + /** + * @throws GuzzleException + */ + public function testAddUserExistingLogin(): void { + self::assertTrue($this->authenticate(), "Authentication failed"); - $this->assertEquals(1, $this->getConnection()->getRowCount('users'), "Wrong row count"); + self::assertEquals(1, $this->getConnection()->getRowCount('users'), "Wrong row count"); $options = [ 'http_errors' => false, 'form_params' => [ 'action' => 'adduser', 'login' => $this->testAdminUser, 'password' => $this->testPass ], ]; $response = $this->http->post('/client/index.php', $options); - $this->assertEquals(200, $response->getStatusCode(), "Unexpected status code"); + self::assertEquals(200, $response->getStatusCode(), "Unexpected status code"); $json = json_decode((string) $response->getBody()); - $this->assertTrue($json->{'error'}, "Unexpected success"); - $this->assertFalse(isset($json->{'userid'}), "Unexpected user id"); - $this->assertEquals(1, $this->getConnection()->getRowCount('users'), "Wrong row count"); + self::assertTrue($json->{'error'}, "Unexpected success"); + self::assertFalse(isset($json->{'userid'}), "Unexpected user id"); + self::assertEquals(1, $this->getConnection()->getRowCount('users'), "Wrong row count"); } - public function testAddUserEmptyLogin() { - $this->assertTrue($this->authenticate(), "Authentication failed"); + /** + * @throws GuzzleException + */ + public function testAddUserEmptyLogin(): void { + self::assertTrue($this->authenticate(), "Authentication failed"); - $this->assertEquals(1, $this->getConnection()->getRowCount('users'), "Wrong row count"); + self::assertEquals(1, $this->getConnection()->getRowCount('users'), "Wrong row count"); $options = [ 'http_errors' => false, 'form_params' => [ 'action' => 'adduser', 'login' => '', 'password' => $this->testPass ], ]; $response = $this->http->post('/client/index.php', $options); - $this->assertEquals(200, $response->getStatusCode(), "Unexpected status code"); + self::assertEquals(200, $response->getStatusCode(), "Unexpected status code"); $json = json_decode((string) $response->getBody()); - $this->assertTrue($json->{'error'}, "Unexpected success"); - $this->assertFalse(isset($json->{'userid'}), "Unexpected user id"); - $this->assertEquals(1, $this->getConnection()->getRowCount('users'), "Wrong row count"); + self::assertTrue($json->{'error'}, "Unexpected success"); + self::assertFalse(isset($json->{'userid'}), "Unexpected user id"); + self::assertEquals(1, $this->getConnection()->getRowCount('users'), "Wrong row count"); } - public function testAddUserEmptyPass() { - $this->assertTrue($this->authenticate(), "Authentication failed"); + /** + * @throws GuzzleException + */ + public function testAddUserEmptyPass(): void { + self::assertTrue($this->authenticate(), "Authentication failed"); - $this->assertEquals(1, $this->getConnection()->getRowCount('users'), "Wrong row count"); + self::assertEquals(1, $this->getConnection()->getRowCount('users'), "Wrong row count"); $options = [ 'http_errors' => false, 'form_params' => [ 'action' => 'adduser', 'login' => $this->testUser, 'password' => '' ], ]; $response = $this->http->post('/client/index.php', $options); - $this->assertEquals(200, $response->getStatusCode(), "Unexpected status code"); + self::assertEquals(200, $response->getStatusCode(), "Unexpected status code"); $json = json_decode((string) $response->getBody()); - $this->assertTrue($json->{'error'}, "Unexpected success"); - $this->assertFalse(isset($json->{'userid'}), "Unexpected user id"); - $this->assertEquals(1, $this->getConnection()->getRowCount('users'), "Wrong row count"); + self::assertTrue($json->{'error'}, "Unexpected success"); + self::assertFalse(isset($json->{'userid'}), "Unexpected user id"); + self::assertEquals(1, $this->getConnection()->getRowCount('users'), "Wrong row count"); } - public function testAddUserNoParameters() { - $this->assertTrue($this->authenticate(), "Authentication failed"); + /** + * @throws GuzzleException + */ + public function testAddUserNoParameters(): void { + self::assertTrue($this->authenticate(), "Authentication failed"); - $this->assertEquals(1, $this->getConnection()->getRowCount('users'), "Wrong row count"); + self::assertEquals(1, $this->getConnection()->getRowCount('users'), "Wrong row count"); $options = [ 'http_errors' => false, 'form_params' => [ 'action' => 'adduser' ], ]; $response = $this->http->post('/client/index.php', $options); - $this->assertEquals(200, $response->getStatusCode(), "Unexpected status code"); + self::assertEquals(200, $response->getStatusCode(), "Unexpected status code"); $json = json_decode((string) $response->getBody()); - $this->assertTrue($json->{'error'}, "Unexpected success"); - $this->assertFalse(isset($json->{'userid'}), "Unexpected user id"); - $this->assertEquals(1, $this->getConnection()->getRowCount('users'), "Wrong row count"); + self::assertTrue($json->{'error'}, "Unexpected success"); + self::assertFalse(isset($json->{'userid'}), "Unexpected user id"); + self::assertEquals(1, $this->getConnection()->getRowCount('users'), "Wrong row count"); } - public function testAddUserByNonAdmin() { + /** + * @throws GuzzleException + */ + public function testAddUserByNonAdmin(): void { $this->addTestUser($this->testUser, password_hash($this->testPass, PASSWORD_DEFAULT)); - $this->assertTrue($this->authenticate($this->testUser, $this->testPass), "Authentication failed"); + self::assertTrue($this->authenticate($this->testUser, $this->testPass), "Authentication failed"); - $this->assertEquals(2, $this->getConnection()->getRowCount('users'), "Wrong row count"); + self::assertEquals(2, $this->getConnection()->getRowCount('users'), "Wrong row count"); $options = [ 'http_errors' => false, 'form_params' => [ 'action' => 'adduser', 'login' => $this->testUser2, 'password' => $this->testPass ], ]; $response = $this->http->post('/client/index.php', $options); - $this->assertEquals(200, $response->getStatusCode(), "Unexpected status code"); + self::assertEquals(200, $response->getStatusCode(), "Unexpected status code"); $json = json_decode((string) $response->getBody()); - $this->assertTrue($json->{'error'}, "Unexpected success"); - $this->assertFalse(isset($json->{'userid'}), "Unexpected user id"); - $this->assertEquals(2, $this->getConnection()->getRowCount('users'), "Wrong row count"); + self::assertTrue($json->{'error'}, "Unexpected success"); + self::assertFalse(isset($json->{'userid'}), "Unexpected user id"); + self::assertEquals(2, $this->getConnection()->getRowCount('users'), "Wrong row count"); } /* addtrack */ + /** + * @throws GuzzleException + */ + public function testAddTrack(): void { + self::assertTrue($this->authenticate(), "Authentication failed"); - public function testAddTrack() { - $this->assertTrue($this->authenticate(), "Authentication failed"); - - $this->assertEquals(0, $this->getConnection()->getRowCount('tracks'), "Wrong row count"); + self::assertEquals(0, $this->getConnection()->getRowCount('tracks'), "Wrong row count"); $options = [ 'http_errors' => false, 'form_params' => [ 'action' => 'addtrack', 'track' => $this->testTrackName ], ]; $response = $this->http->post('/client/index.php', $options); - $this->assertEquals(200, $response->getStatusCode(), "Unexpected status code"); + self::assertEquals(200, $response->getStatusCode(), "Unexpected status code"); $json = json_decode((string) $response->getBody()); - $this->assertFalse($json->{'error'}, "Unexpected error"); - $this->assertEquals(1, $json->{'trackid'}, "Wrong track id"); - $this->assertEquals(1, $this->getConnection()->getRowCount('tracks'), "Wrong row count"); + self::assertFalse($json->{'error'}, "Unexpected error"); + self::assertEquals(1, $json->{'trackid'}, "Wrong track id"); + self::assertEquals(1, $this->getConnection()->getRowCount('tracks'), "Wrong row count"); $expected = [ "id" => 1, "user_id" => 1, "name" => $this->testTrackName ]; $actual = $this->getConnection()->createQueryTable("users", "SELECT id, user_id, name FROM tracks"); $this->assertTableContains($expected, $actual, "Wrong actual table data"); } - public function testAddTrackEmptyName() { - $this->assertTrue($this->authenticate(), "Authentication failed"); + /** + * @throws GuzzleException + */ + public function testAddTrackEmptyName(): void { + self::assertTrue($this->authenticate(), "Authentication failed"); - $this->assertEquals(0, $this->getConnection()->getRowCount('tracks'), "Wrong row count"); + self::assertEquals(0, $this->getConnection()->getRowCount('tracks'), "Wrong row count"); $options = [ 'http_errors' => false, 'form_params' => [ 'action' => 'addtrack', 'track' => '' ], ]; $response = $this->http->post('/client/index.php', $options); - $this->assertEquals(200, $response->getStatusCode(), "Unexpected status code"); + self::assertEquals(200, $response->getStatusCode(), "Unexpected status code"); $json = json_decode((string) $response->getBody()); - $this->assertTrue($json->{'error'}, "Unexpected success"); - $this->assertFalse(isset($json->{'trackid'}), "Unexpected track id"); - $this->assertEquals(0, $this->getConnection()->getRowCount('tracks'), "Wrong row count"); + self::assertTrue($json->{'error'}, "Unexpected success"); + self::assertFalse(isset($json->{'trackid'}), "Unexpected track id"); + self::assertEquals(0, $this->getConnection()->getRowCount('tracks'), "Wrong row count"); } - public function testAddTrackNoParameters() { - $this->assertTrue($this->authenticate(), "Authentication failed"); + /** + * @throws GuzzleException + */ + public function testAddTrackNoParameters(): void { + self::assertTrue($this->authenticate(), "Authentication failed"); - $this->assertEquals(0, $this->getConnection()->getRowCount('tracks'), "Wrong row count"); + self::assertEquals(0, $this->getConnection()->getRowCount('tracks'), "Wrong row count"); $options = [ 'http_errors' => false, 'form_params' => [ 'action' => 'addtrack' ], ]; $response = $this->http->post('/client/index.php', $options); - $this->assertEquals(200, $response->getStatusCode(), "Unexpected status code"); + self::assertEquals(200, $response->getStatusCode(), "Unexpected status code"); $json = json_decode((string) $response->getBody()); - $this->assertTrue($json->{'error'}, "Unexpected success"); - $this->assertFalse(isset($json->{'trackid'}), "Unexpected track id"); - $this->assertEquals(0, $this->getConnection()->getRowCount('tracks'), "Wrong row count"); + self::assertTrue($json->{'error'}, "Unexpected success"); + self::assertFalse(isset($json->{'trackid'}), "Unexpected track id"); + self::assertEquals(0, $this->getConnection()->getRowCount('tracks'), "Wrong row count"); } /* addpos */ - - public function testAddPosition() { - $this->assertTrue($this->authenticate(), "Authentication failed"); + /** + * @throws GuzzleException + */ + public function testAddPosition(): void { + self::assertTrue($this->authenticate(), "Authentication failed"); $trackId = $this->addTestTrack($this->testUserId); - $this->assertEquals(1, $this->getConnection()->getRowCount('tracks'), "Wrong row count"); - $this->assertEquals(0, $this->getConnection()->getRowCount('positions'), "Wrong row count"); + self::assertEquals(1, $this->getConnection()->getRowCount('tracks'), "Wrong row count"); + self::assertEquals(0, $this->getConnection()->getRowCount('positions'), "Wrong row count"); $options = [ 'http_errors' => false, @@ -228,10 +266,10 @@ class ClientAPITest extends UloggerAPITestCase { ], ]; $response = $this->http->post('/client/index.php', $options); - $this->assertEquals(200, $response->getStatusCode(), "Unexpected status code"); + self::assertEquals(200, $response->getStatusCode(), "Unexpected status code"); $json = json_decode((string) $response->getBody()); - $this->assertFalse($json->{'error'}, "Unexpected error"); - $this->assertEquals(1, $this->getConnection()->getRowCount('positions'), "Wrong row count"); + self::assertFalse($json->{'error'}, "Unexpected error"); + self::assertEquals(1, $this->getConnection()->getRowCount('positions'), "Wrong row count"); $expected = [ "id" => 1, "user_id" => $this->testUserId, @@ -254,12 +292,15 @@ class ClientAPITest extends UloggerAPITestCase { $this->assertTableContains($expected, $actual, "Wrong actual table data"); } - public function testAddPositionWithImage() { - $this->assertTrue($this->authenticate(), "Authentication failed"); + /** + * @throws GuzzleException + */ + public function testAddPositionWithImage(): void { + self::assertTrue($this->authenticate(), "Authentication failed"); $trackId = $this->addTestTrack($this->testUserId); - $this->assertEquals(1, $this->getConnection()->getRowCount('tracks'), "Wrong row count"); - $this->assertEquals(0, $this->getConnection()->getRowCount('positions'), "Wrong row count"); + self::assertEquals(1, $this->getConnection()->getRowCount('tracks'), "Wrong row count"); + self::assertEquals(0, $this->getConnection()->getRowCount('positions'), "Wrong row count"); $options = [ 'http_errors' => false, @@ -317,10 +358,10 @@ class ClientAPITest extends UloggerAPITestCase { ] ]; $response = $this->http->post('/client/index.php', $options); - $this->assertEquals(200, $response->getStatusCode(), "Unexpected status code"); + self::assertEquals(200, $response->getStatusCode(), "Unexpected status code"); $json = json_decode((string) $response->getBody()); - $this->assertFalse($json->{'error'}, "Unexpected error"); - $this->assertEquals(1, $this->getConnection()->getRowCount('positions'), "Wrong row count"); + self::assertFalse($json->{'error'}, "Unexpected error"); + self::assertEquals(1, $this->getConnection()->getRowCount('positions'), "Wrong row count"); $expected = [ "id" => 1, "user_id" => $this->testUserId, @@ -339,26 +380,29 @@ class ClientAPITest extends UloggerAPITestCase { "positions", "SELECT id, user_id, track_id, " . $this->unix_timestamp('time') . " AS time, latitude, longitude, altitude, speed, bearing, accuracy, provider, comment, image FROM positions" ); - $this->assertEquals($expected['id'], $actual->getValue(0, 'id')); - $this->assertEquals($expected['user_id'], $actual->getValue(0, 'user_id')); - $this->assertEquals($expected['track_id'], $actual->getValue(0, 'track_id')); - $this->assertEquals($expected['time'], $actual->getValue(0, 'time')); - $this->assertEquals($expected['latitude'], $actual->getValue(0, 'latitude')); - $this->assertEquals($expected['longitude'], $actual->getValue(0, 'longitude')); - $this->assertEquals($expected['altitude'], $actual->getValue(0, 'altitude')); - $this->assertEquals($expected['speed'], $actual->getValue(0, 'speed')); - $this->assertEquals($expected['bearing'], $actual->getValue(0, 'bearing')); - $this->assertEquals($expected['accuracy'], $actual->getValue(0, 'accuracy')); - $this->assertEquals($expected['provider'], $actual->getValue(0, 'provider')); - $this->assertEquals($expected['comment'], $actual->getValue(0, 'comment')); - $this->assertContains('.jpg', $actual->getValue(0, 'image')); + self::assertEquals($expected['id'], $actual->getValue(0, 'id')); + self::assertEquals($expected['user_id'], $actual->getValue(0, 'user_id')); + self::assertEquals($expected['track_id'], $actual->getValue(0, 'track_id')); + self::assertEquals($expected['time'], $actual->getValue(0, 'time')); + self::assertEquals($expected['latitude'], $actual->getValue(0, 'latitude')); + self::assertEquals($expected['longitude'], $actual->getValue(0, 'longitude')); + self::assertEquals($expected['altitude'], $actual->getValue(0, 'altitude')); + self::assertEquals($expected['speed'], $actual->getValue(0, 'speed')); + self::assertEquals($expected['bearing'], $actual->getValue(0, 'bearing')); + self::assertEquals($expected['accuracy'], $actual->getValue(0, 'accuracy')); + self::assertEquals($expected['provider'], $actual->getValue(0, 'provider')); + self::assertEquals($expected['comment'], $actual->getValue(0, 'comment')); + self::assertStringContainsString('.jpg', $actual->getValue(0, 'image')); } - public function testAddPositionNoexistantTrack() { - $this->assertTrue($this->authenticate(), "Authentication failed"); + /** + * @throws GuzzleException + */ + public function testAddPositionNoexistantTrack(): void { + self::assertTrue($this->authenticate(), "Authentication failed"); - $this->assertEquals(0, $this->getConnection()->getRowCount('tracks'), "Wrong row count"); - $this->assertEquals(0, $this->getConnection()->getRowCount('positions'), "Wrong row count"); + self::assertEquals(0, $this->getConnection()->getRowCount('tracks'), "Wrong row count"); + self::assertEquals(0, $this->getConnection()->getRowCount('positions'), "Wrong row count"); $options = [ 'http_errors' => false, @@ -378,18 +422,21 @@ class ClientAPITest extends UloggerAPITestCase { ], ]; $response = $this->http->post('/client/index.php', $options); - $this->assertEquals(200, $response->getStatusCode(), "Unexpected status code"); + self::assertEquals(200, $response->getStatusCode(), "Unexpected status code"); $json = json_decode((string) $response->getBody()); - $this->assertTrue($json->{'error'}, "Unexpected success"); - $this->assertEquals(0, $this->getConnection()->getRowCount('positions'), "Wrong row count"); + self::assertTrue($json->{'error'}, "Unexpected success"); + self::assertEquals(0, $this->getConnection()->getRowCount('positions'), "Wrong row count"); } - public function testAddPositionEmptyParameters() { - $this->assertTrue($this->authenticate(), "Authentication failed"); + /** + * @throws GuzzleException + */ + public function testAddPositionEmptyParameters(): void { + self::assertTrue($this->authenticate(), "Authentication failed"); $trackId = $this->addTestTrack($this->testUserId); - $this->assertEquals(1, $this->getConnection()->getRowCount('tracks'), "Wrong row count"); - $this->assertEquals(0, $this->getConnection()->getRowCount('positions'), "Wrong row count"); + self::assertEquals(1, $this->getConnection()->getRowCount('tracks'), "Wrong row count"); + self::assertEquals(0, $this->getConnection()->getRowCount('positions'), "Wrong row count"); $options = [ 'http_errors' => false, @@ -414,19 +461,22 @@ class ClientAPITest extends UloggerAPITestCase { $optCopy = $options; $optCopy['form_params'][$parameter] = ''; $response = $this->http->post('/client/index.php', $optCopy); - $this->assertEquals(200, $response->getStatusCode(), "Unexpected status code"); + self::assertEquals(200, $response->getStatusCode(), "Unexpected status code"); $json = json_decode((string) $response->getBody()); - $this->assertTrue($json->{'error'}, "Unexpected success ($parameter)"); + self::assertTrue($json->{'error'}, "Unexpected success ($parameter)"); } - $this->assertEquals(0, $this->getConnection()->getRowCount('positions'), "Wrong row count"); + self::assertEquals(0, $this->getConnection()->getRowCount('positions'), "Wrong row count"); } - public function testAddPositionMissingParameters() { - $this->assertTrue($this->authenticate(), "Authentication failed"); + /** + * @throws GuzzleException + */ + public function testAddPositionMissingParameters(): void { + self::assertTrue($this->authenticate(), "Authentication failed"); $trackId = $this->addTestTrack($this->testUserId); - $this->assertEquals(1, $this->getConnection()->getRowCount('tracks'), "Wrong row count"); - $this->assertEquals(0, $this->getConnection()->getRowCount('positions'), "Wrong row count"); + self::assertEquals(1, $this->getConnection()->getRowCount('tracks'), "Wrong row count"); + self::assertEquals(0, $this->getConnection()->getRowCount('positions'), "Wrong row count"); $options = [ 'http_errors' => false, @@ -451,11 +501,11 @@ class ClientAPITest extends UloggerAPITestCase { $optCopy = $options; unset($optCopy['form_params'][$parameter]); $response = $this->http->post('/client/index.php', $optCopy); - $this->assertEquals(200, $response->getStatusCode(), "Unexpected status code"); + self::assertEquals(200, $response->getStatusCode(), "Unexpected status code"); $json = json_decode((string) $response->getBody()); - $this->assertTrue($json->{'error'}, "Unexpected success ($parameter)"); + self::assertTrue($json->{'error'}, "Unexpected success ($parameter)"); } - $this->assertEquals(0, $this->getConnection()->getRowCount('positions'), "Wrong row count"); + self::assertEquals(0, $this->getConnection()->getRowCount('positions'), "Wrong row count"); // optional $optional = [ 'altitude', 'speed', 'bearing', 'accuracy', 'provider', 'comment', 'imageid' ]; @@ -463,11 +513,11 @@ class ClientAPITest extends UloggerAPITestCase { $optCopy = $options; unset($optCopy['form_params'][$parameter]); $response = $this->http->post('/client/index.php', $optCopy); - $this->assertEquals(200, $response->getStatusCode(), "Unexpected status code"); + self::assertEquals(200, $response->getStatusCode(), "Unexpected status code"); $json = json_decode((string) $response->getBody()); - $this->assertFalse($json->{'error'}, "Unexpected error ($parameter)"); + self::assertFalse($json->{'error'}, "Unexpected error ($parameter)"); } - $this->assertEquals(count($optional), $this->getConnection()->getRowCount('positions'), "Wrong row count"); + self::assertEquals(count($optional), $this->getConnection()->getRowCount('positions'), "Wrong row count"); } diff --git a/.tests/tests/ConfigTest.php b/.tests/tests/ConfigTest.php index 241f71f..157ebd6 100644 --- a/.tests/tests/ConfigTest.php +++ b/.tests/tests/ConfigTest.php @@ -1,5 +1,7 @@ config = uConfig::getInstance(); $this->initConfigValues(); } - /** - * @throws ReflectionException - */ - protected function tearDown() { + protected function tearDown(): void { parent::tearDown(); $configClass = new ReflectionClass("uConfig"); $configInstance = $configClass->getProperty('instance'); @@ -43,7 +42,7 @@ class ConfigTest extends UloggerDatabaseTestCase { $configInstance->setValue(null); } - protected function getDataSet() { + protected function getDataSet(): IDataSet { $this->initConfigValues(); $this->resetAutoincrement(); $dataset = [ @@ -71,28 +70,28 @@ class ConfigTest extends UloggerDatabaseTestCase { return $this->createArrayDataSet($dataset); } - public function testSetFromDatabase() { - $this->assertEquals($this->mapApi, $this->config->mapApi); - $this->assertEquals($this->latitude, $this->config->initLatitude); - $this->assertEquals($this->longitude, $this->config->initLongitude); - $this->assertEquals($this->googleKey, $this->config->googleKey); - $this->assertEquals($this->requireAuth, $this->config->requireAuthentication); - $this->assertEquals($this->publicTracks, $this->config->publicTracks); - $this->assertEquals($this->passLenMin, $this->config->passLenMin); - $this->assertEquals($this->passStrength, $this->config->passStrength); - $this->assertEquals($this->interval, $this->config->interval); - $this->assertEquals($this->lang, $this->config->lang); - $this->assertEquals($this->units, $this->config->units); - $this->assertEquals($this->strokeWeight, $this->config->strokeWeight); - $this->assertEquals($this->strokeColor, $this->config->strokeColor); - $this->assertEquals($this->strokeOpacity, $this->config->strokeOpacity); + public function testSetFromDatabase(): void { + self::assertEquals($this->mapApi, $this->config->mapApi); + self::assertEquals($this->latitude, $this->config->initLatitude); + self::assertEquals($this->longitude, $this->config->initLongitude); + self::assertEquals($this->googleKey, $this->config->googleKey); + self::assertEquals($this->requireAuth, $this->config->requireAuthentication); + self::assertEquals($this->publicTracks, $this->config->publicTracks); + self::assertEquals($this->passLenMin, $this->config->passLenMin); + self::assertEquals($this->passStrength, $this->config->passStrength); + self::assertEquals($this->interval, $this->config->interval); + self::assertEquals($this->lang, $this->config->lang); + self::assertEquals($this->units, $this->config->units); + self::assertEquals($this->strokeWeight, $this->config->strokeWeight); + self::assertEquals($this->strokeColor, $this->config->strokeColor); + self::assertEquals($this->strokeOpacity, $this->config->strokeOpacity); - $this->assertEquals($this->testLayer, $this->config->olLayers[0]->name); - $this->assertEquals($this->testUrl, $this->config->olLayers[0]->url); - $this->assertEquals($this->testPriority, $this->config->olLayers[0]->priority); + self::assertEquals($this->testLayer, $this->config->olLayers[0]->name); + self::assertEquals($this->testUrl, $this->config->olLayers[0]->url); + self::assertEquals($this->testPriority, $this->config->olLayers[0]->priority); } - public function testSave() { + public function testSave(): void { $this->config->mapApi = 'newApi'; $this->config->initLatitude = 33.11; $this->config->initLongitude = 22.11; @@ -129,16 +128,16 @@ class ConfigTest extends UloggerDatabaseTestCase { "stroke_opacity" => $this->config->strokeOpacity ]; $cnt = count($expected); - $this->assertGreaterThanOrEqual($cnt, $this->getConnection()->getRowCount('config'), "Wrong row count"); + self::assertGreaterThanOrEqual($cnt, $this->getConnection()->getRowCount('config'), "Wrong row count"); $actual = $this->getConnection()->createQueryTable("config", "SELECT * FROM config"); for ($i = 0; $i < $cnt; $i++) { $row = $actual->getRow($i); $actualValue = $row['value']; if (isset($expected[$row['name']])) { - $this->assertEquals(serialize($expected[$row['name']]), is_resource($actualValue) ? stream_get_contents($actualValue) : $actualValue); + self::assertEquals(serialize($expected[$row['name']]), is_resource($actualValue) ? stream_get_contents($actualValue) : $actualValue); } } - $this->assertEquals(1, $this->getConnection()->getRowCount('ol_layers'), "Wrong row count"); + self::assertEquals(1, $this->getConnection()->getRowCount('ol_layers'), "Wrong row count"); $expected = [ "id" => $this->config->olLayers[0]->id, "name" => $this->config->olLayers[0]->name, @@ -149,7 +148,7 @@ class ConfigTest extends UloggerDatabaseTestCase { $this->assertTableContains($expected, $actual, "Wrong actual table data: " . implode(', ', $actual->getRow(0))); } - private function initConfigValues() { + private function initConfigValues(): void { $this->mapApi = 'testApi'; $this->latitude = 33.33; $this->longitude = 22.22; @@ -169,7 +168,7 @@ class ConfigTest extends UloggerDatabaseTestCase { $this->testPriority = 5; } - public function testPassRegex() { + public function testPassRegex(): void { $this->config->passLenMin = 0; $this->config->passStrength = 0; $password0 = "password"; @@ -178,49 +177,49 @@ class ConfigTest extends UloggerDatabaseTestCase { $password3 = "PASSword1234-;"; $regex = $this->config->passRegex(); - $this->assertRegExp($regex, $password0, "Regex: \"$regex\", password: \"$password0\""); - $this->assertRegExp($regex, $password1, "Regex: \"$regex\", password: \"$password1\""); - $this->assertRegExp($regex, $password2, "Regex: \"$regex\", password: \"$password2\""); - $this->assertRegExp($regex, $password3, "Regex: \"$regex\", password: \"$password3\""); + self::assertMatchesRegularExpression($regex, $password0, "Regex: \"$regex\", password: \"$password0\""); + self::assertMatchesRegularExpression($regex, $password1, "Regex: \"$regex\", password: \"$password1\""); + self::assertMatchesRegularExpression($regex, $password2, "Regex: \"$regex\", password: \"$password2\""); + self::assertMatchesRegularExpression($regex, $password3, "Regex: \"$regex\", password: \"$password3\""); $this->config->passStrength = 1; $regex = $this->config->passRegex(); - $this->assertNotRegExp($regex, $password0, "Regex: \"$regex\", password: \"$password0\""); - $this->assertRegExp($regex, $password1, "Regex: \"$regex\", password: \"$password1\""); - $this->assertRegExp($regex, $password2, "Regex: \"$regex\", password: \"$password2\""); - $this->assertRegExp($regex, $password3, "Regex: \"$regex\", password: \"$password3\""); + self::assertDoesNotMatchRegularExpression($regex, $password0, "Regex: \"$regex\", password: \"$password0\""); + self::assertMatchesRegularExpression($regex, $password1, "Regex: \"$regex\", password: \"$password1\""); + self::assertMatchesRegularExpression($regex, $password2, "Regex: \"$regex\", password: \"$password2\""); + self::assertMatchesRegularExpression($regex, $password3, "Regex: \"$regex\", password: \"$password3\""); $this->config->passStrength = 2; $regex = $this->config->passRegex(); - $this->assertNotRegExp($regex, $password0, "Regex: \"$regex\", password: \"$password0\""); - $this->assertNotRegExp($regex, $password1, "Regex: \"$regex\", password: \"$password1\""); - $this->assertRegExp($regex, $password2, "Regex: \"$regex\", password: \"$password2\""); - $this->assertRegExp($regex, $password3, "Regex: \"$regex\", password: \"$password3\""); + self::assertDoesNotMatchRegularExpression($regex, $password0, "Regex: \"$regex\", password: \"$password0\""); + self::assertDoesNotMatchRegularExpression($regex, $password1, "Regex: \"$regex\", password: \"$password1\""); + self::assertMatchesRegularExpression($regex, $password2, "Regex: \"$regex\", password: \"$password2\""); + self::assertMatchesRegularExpression($regex, $password3, "Regex: \"$regex\", password: \"$password3\""); $this->config->passStrength = 3; $regex = $this->config->passRegex(); - $this->assertNotRegExp($regex, $password0, "Regex: \"$regex\", password: \"$password0\""); - $this->assertNotRegExp($regex, $password1, "Regex: \"$regex\", password: \"$password1\""); - $this->assertNotRegExp($regex, $password2, "Regex: \"$regex\", password: \"$password2\""); - $this->assertRegExp($regex, $password3, "Regex: \"$regex\", password: \"$password3\""); + self::assertDoesNotMatchRegularExpression($regex, $password0, "Regex: \"$regex\", password: \"$password0\""); + self::assertDoesNotMatchRegularExpression($regex, $password1, "Regex: \"$regex\", password: \"$password1\""); + self::assertDoesNotMatchRegularExpression($regex, $password2, "Regex: \"$regex\", password: \"$password2\""); + self::assertMatchesRegularExpression($regex, $password3, "Regex: \"$regex\", password: \"$password3\""); $password_len5 = "12345"; $password_len10 = "1234567890"; $this->config->passLenMin = 5; $this->config->passStrength = 0; $regex = $this->config->passRegex(); - $this->assertRegExp($regex, $password_len5, "Regex: \"$regex\", password: \"$password_len5\""); - $this->assertRegExp($regex, $password_len10, "Regex: \"$regex\", password: \"$password_len10\""); + self::assertMatchesRegularExpression($regex, $password_len5, "Regex: \"$regex\", password: \"$password_len5\""); + self::assertMatchesRegularExpression($regex, $password_len10, "Regex: \"$regex\", password: \"$password_len10\""); $this->config->passLenMin = 7; $regex = $this->config->passRegex(); - $this->assertNotRegExp($regex, $password_len5, "Regex: \"$regex\", password: \"$password_len5\""); - $this->assertRegExp($regex, $password_len10, "Regex: \"$regex\", password: \"$password_len10\""); + self::assertDoesNotMatchRegularExpression($regex, $password_len5, "Regex: \"$regex\", password: \"$password_len5\""); + self::assertMatchesRegularExpression($regex, $password_len10, "Regex: \"$regex\", password: \"$password_len10\""); $this->config->passLenMin = 12; $regex = $this->config->passRegex(); - $this->assertNotRegExp($regex, $password_len5, "Regex: \"$regex\", password: \"$password_len5\""); - $this->assertNotRegExp($regex, $password_len10, "Regex: \"$regex\", password: \"$password_len10\""); + self::assertDoesNotMatchRegularExpression($regex, $password_len5, "Regex: \"$regex\", password: \"$password_len5\""); + self::assertDoesNotMatchRegularExpression($regex, $password_len10, "Regex: \"$regex\", password: \"$password_len10\""); } } ?> diff --git a/.tests/tests/DbTest.php b/.tests/tests/DbTest.php index 57ce7a1..bcf7cb1 100644 --- a/.tests/tests/DbTest.php +++ b/.tests/tests/DbTest.php @@ -6,7 +6,7 @@ require_once(__DIR__ . "/../../helpers/db.php"); class DbTest extends TestCase { - public function testGetDbNameValidNames() { + public function testGetDbNameValidNames(): void { $testDbName = "testDbName"; $defaultDSNs = [ "mysql:host=db.example.com;port=3306;dbname=$testDbName", @@ -22,11 +22,11 @@ class DbTest extends TestCase { ]; foreach ($defaultDSNs as $dsn) { - $this->assertEquals($testDbName, uDb::getDbName($dsn)); + self::assertEquals($testDbName, uDb::getDbName($dsn)); } } - public function testGetDbNameEmptyNames() { + public function testGetDbNameEmptyNames(): void { $testDbName = ""; $defaultDSNs = [ "mysql:host=db.example.com;port=3306;dbname=", @@ -42,12 +42,12 @@ class DbTest extends TestCase { ]; foreach ($defaultDSNs as $dsn) { - $this->assertEquals($testDbName, uDb::getDbName($dsn)); + self::assertEquals($testDbName, uDb::getDbName($dsn)); } } - public function testGetDbFilename() { + public function testGetDbFilename(): void { $testFileNames = [ "C:\\Program Files\\Database.db", ":memory:", @@ -55,11 +55,11 @@ class DbTest extends TestCase { ]; foreach ($testFileNames as $fileName) { - $this->assertEquals($fileName, uDb::getDbName("sqlite:$fileName")); + self::assertEquals($fileName, uDb::getDbName("sqlite:$fileName")); } } - public function testNormalizeDsn() { + public function testNormalizeDsn(): void { $testDbName = "testDbName"; $nonSqlite = [ "mysql:host=db.example.com;port=3306;dbname=$testDbName", @@ -72,12 +72,12 @@ class DbTest extends TestCase { ]; foreach ($nonSqlite as $dsn) { - $this->assertEquals($dsn, uDb::normalizeDsn($dsn)); + self::assertEquals($dsn, uDb::normalizeDsn($dsn)); } - $this->assertEquals("sqlite:" . realpath(ROOT_DIR . "/index.php"), uDb::normalizeDsn("sqlite:index.php")); - $this->assertEquals("sqlite:" . realpath(ROOT_DIR . "/index.php"), uDb::normalizeDsn("sqlite:helpers/../index.php")); - $this->assertNotEquals("sqlite:" . realpath(ROOT_DIR . "/index.php"), uDb::normalizeDsn("sqlite:../index.php")); + self::assertEquals("sqlite:" . realpath(ROOT_DIR . "/index.php"), uDb::normalizeDsn("sqlite:index.php")); + self::assertEquals("sqlite:" . realpath(ROOT_DIR . "/index.php"), uDb::normalizeDsn("sqlite:helpers/../index.php")); + self::assertNotEquals("sqlite:" . realpath(ROOT_DIR . "/index.php"), uDb::normalizeDsn("sqlite:../index.php")); } } diff --git a/.tests/tests/ImportTest.php b/.tests/tests/ImportTest.php index 904366a..2778dcd 100644 --- a/.tests/tests/ImportTest.php +++ b/.tests/tests/ImportTest.php @@ -1,6 +1,6 @@ assertTrue($this->authenticate(), "Authentication failed"); + self::assertTrue($this->authenticate(), "Authentication failed"); - $this->assertEquals(0, $this->getConnection()->getRowCount("tracks"), "Wrong row count"); - $this->assertEquals(0, $this->getConnection()->getRowCount("positions"), "Wrong row count"); + self::assertEquals(0, $this->getConnection()->getRowCount("tracks"), "Wrong row count"); + self::assertEquals(0, $this->getConnection()->getRowCount("positions"), "Wrong row count"); $gpx10 = ' + xsi:schemaLocation="http://www.topografix.com/GPX/1/0 http://www.topografix.com/GPX/1/0/gpx.xsd"> ' . $this->testTrackName . ' @@ -52,18 +54,18 @@ class ImportTest extends UloggerAPITestCase { ], ]; $response = $this->http->post("/utils/import.php", $options); - $this->assertEquals(200, $response->getStatusCode(), "Unexpected status code"); + self::assertEquals(200, $response->getStatusCode(), "Unexpected status code"); $json = json_decode($response->getBody()); - $this->assertNotNull($json, "JSON object is null"); - $this->assertEquals(count($json), 1, "Wrong count of tracks"); + self::assertNotNull($json, "JSON object is null"); + self::assertCount(1, $json, "Wrong count of tracks"); $track = $json[0]; - $this->assertEquals(1, (int) $track->id, "Wrong track id"); - $this->assertEquals($this->testTrackName, $track->name, "Wrong track name"); + self::assertEquals(1, (int) $track->id, "Wrong track id"); + self::assertEquals($this->testTrackName, $track->name, "Wrong track name"); - $this->assertEquals(1, $this->getConnection()->getRowCount("tracks"), "Wrong row count"); - $this->assertEquals(2, $this->getConnection()->getRowCount("positions"), "Wrong row count"); + self::assertEquals(1, $this->getConnection()->getRowCount("tracks"), "Wrong row count"); + self::assertEquals(2, $this->getConnection()->getRowCount("positions"), "Wrong row count"); $expected = [ "id" => 1, @@ -116,12 +118,15 @@ class ImportTest extends UloggerAPITestCase { $this->assertTableContains($expected, $actual, "Wrong actual table data"); } - public function testImportGPX11() { + /** + * @throws GuzzleException + */ + public function testImportGPX11(): void { - $this->assertTrue($this->authenticate(), "Authentication failed"); + self::assertTrue($this->authenticate(), "Authentication failed"); - $this->assertEquals(0, $this->getConnection()->getRowCount("tracks"), "Wrong row count"); - $this->assertEquals(0, $this->getConnection()->getRowCount("positions"), "Wrong row count"); + self::assertEquals(0, $this->getConnection()->getRowCount("tracks"), "Wrong row count"); + self::assertEquals(0, $this->getConnection()->getRowCount("positions"), "Wrong row count"); $gpx11 = ' Track for testing ulogger Bartek Fabiszewski - fabiszewski.net + fabiszewski.net Test, ulogger @@ -142,7 +147,7 @@ class ImportTest extends UloggerAPITestCase { Crafted by Bartek Fabiszewski - fabiszewski.net + fabiszewski.net ' . $this->testAltitude . ' @@ -169,19 +174,19 @@ class ImportTest extends UloggerAPITestCase { ], ]; $response = $this->http->post("/utils/import.php", $options); - $this->assertEquals(200, $response->getStatusCode(), "Unexpected status code"); + self::assertEquals(200, $response->getStatusCode(), "Unexpected status code"); $json = json_decode($response->getBody()); - $this->assertNotNull($json, "JSON object is null"); - $this->assertEquals(count($json), 1, "Wrong count of tracks"); + self::assertNotNull($json, "JSON object is null"); + self::assertCount(1, $json, "Wrong count of tracks"); $track = $json[0]; - $this->assertEquals(1, (int) $track->id, "Wrong track id"); - $this->assertEquals($this->testTrackName, $track->name, "Wrong track name"); + self::assertEquals(1, (int) $track->id, "Wrong track id"); + self::assertEquals($this->testTrackName, $track->name, "Wrong track name"); - $this->assertEquals(1, $this->getConnection()->getRowCount("tracks"), "Wrong row count"); - $this->assertEquals(1, $this->getConnection()->getRowCount("positions"), "Wrong row count"); + self::assertEquals(1, $this->getConnection()->getRowCount("tracks"), "Wrong row count"); + self::assertEquals(1, $this->getConnection()->getRowCount("positions"), "Wrong row count"); $expected = [ "id" => 1, @@ -217,12 +222,15 @@ class ImportTest extends UloggerAPITestCase { $this->assertTableContains($expected, $actual, "Wrong actual table data"); } - public function testImportExtensions() { + /** + * @throws GuzzleException + */ + public function testImportExtensions(): void { - $this->assertTrue($this->authenticate(), "Authentication failed"); + self::assertTrue($this->authenticate(), "Authentication failed"); - $this->assertEquals(0, $this->getConnection()->getRowCount("tracks"), "Wrong row count"); - $this->assertEquals(0, $this->getConnection()->getRowCount("positions"), "Wrong row count"); + self::assertEquals(0, $this->getConnection()->getRowCount("tracks"), "Wrong row count"); + self::assertEquals(0, $this->getConnection()->getRowCount("positions"), "Wrong row count"); $gpx = ' assertEquals(200, $response->getStatusCode(), "Unexpected status code"); + self::assertEquals(200, $response->getStatusCode(), "Unexpected status code"); $json = json_decode($response->getBody()); - $this->assertNotNull($json, "JSON object is null"); - $this->assertEquals(count($json), 1, "Wrong count of tracks"); + self::assertNotNull($json, "JSON object is null"); + self::assertCount(1, $json, "Wrong count of tracks"); $track = $json[0]; - $this->assertEquals(1, (int) $track->id, "Wrong track id"); - $this->assertEquals($this->testTrackName, $track->name, "Wrong track name"); + self::assertEquals(1, (int) $track->id, "Wrong track id"); + self::assertEquals($this->testTrackName, $track->name, "Wrong track name"); - $this->assertEquals(1, $this->getConnection()->getRowCount("tracks"), "Wrong row count"); - $this->assertEquals(1, $this->getConnection()->getRowCount("positions"), "Wrong row count"); + self::assertEquals(1, $this->getConnection()->getRowCount("tracks"), "Wrong row count"); + self::assertEquals(1, $this->getConnection()->getRowCount("positions"), "Wrong row count"); $expected = [ "id" => 1, @@ -319,16 +327,18 @@ class ImportTest extends UloggerAPITestCase { $this->assertTableContains($expected, $actual, "Wrong actual table data"); } - public function testImportNoTime() { + /** + * @throws GuzzleException + */ + public function testImportNoTime(): void { - $this->assertTrue($this->authenticate(), "Authentication failed"); + self::assertTrue($this->authenticate(), "Authentication failed"); - $this->assertEquals(0, $this->getConnection()->getRowCount("tracks"), "Wrong row count"); - $this->assertEquals(0, $this->getConnection()->getRowCount("positions"), "Wrong row count"); + self::assertEquals(0, $this->getConnection()->getRowCount("tracks"), "Wrong row count"); + self::assertEquals(0, $this->getConnection()->getRowCount("positions"), "Wrong row count"); $gpx = ' - @@ -354,19 +364,19 @@ class ImportTest extends UloggerAPITestCase { ], ]; $response = $this->http->post("/utils/import.php", $options); - $this->assertEquals(200, $response->getStatusCode(), "Unexpected status code"); + self::assertEquals(200, $response->getStatusCode(), "Unexpected status code"); $json = json_decode($response->getBody()); - $this->assertNotNull($json, "JSON object is null"); - $this->assertEquals(count($json), 1, "Wrong count of tracks"); + self::assertNotNull($json, "JSON object is null"); + self::assertCount(1, $json, "Wrong count of tracks"); $track = $json[0]; - $this->assertEquals(1, (int) $track->id, "Wrong track id"); - $this->assertEquals($this->testTrackName, $track->name, "Wrong track name"); + self::assertEquals(1, (int) $track->id, "Wrong track id"); + self::assertEquals($this->testTrackName, $track->name, "Wrong track name"); - $this->assertEquals(1, $this->getConnection()->getRowCount("tracks"), "Wrong row count"); - $this->assertEquals(1, $this->getConnection()->getRowCount("positions"), "Wrong row count"); + self::assertEquals(1, $this->getConnection()->getRowCount("tracks"), "Wrong row count"); + self::assertEquals(1, $this->getConnection()->getRowCount("positions"), "Wrong row count"); $expected = [ "id" => 1, @@ -402,12 +412,15 @@ class ImportTest extends UloggerAPITestCase { $this->assertTableContains($expected, $actual, "Wrong actual table data"); } - public function testImportMultipleSegments() { + /** + * @throws GuzzleException + */ + public function testImportMultipleSegments(): void { - $this->assertTrue($this->authenticate(), "Authentication failed"); + self::assertTrue($this->authenticate(), "Authentication failed"); - $this->assertEquals(0, $this->getConnection()->getRowCount("tracks"), "Wrong row count"); - $this->assertEquals(0, $this->getConnection()->getRowCount("positions"), "Wrong row count"); + self::assertEquals(0, $this->getConnection()->getRowCount("tracks"), "Wrong row count"); + self::assertEquals(0, $this->getConnection()->getRowCount("positions"), "Wrong row count"); $gpx = ' http->post("/utils/import.php", $options); - $this->assertEquals(200, $response->getStatusCode(), "Unexpected status code"); + self::assertEquals(200, $response->getStatusCode(), "Unexpected status code"); $json = json_decode($response->getBody()); - $this->assertNotNull($json, "JSON object is null"); - $this->assertEquals(count($json), 1, "Wrong count of tracks"); + self::assertNotNull($json, "JSON object is null"); + self::assertCount(1, $json, "Wrong count of tracks"); $track = $json[0]; - $this->assertEquals(1, (int) $track->id, "Wrong track id"); - $this->assertEquals($this->testTrackName, $track->name, "Wrong track name"); + self::assertEquals(1, (int) $track->id, "Wrong track id"); + self::assertEquals($this->testTrackName, $track->name, "Wrong track name"); - $this->assertEquals(1, $this->getConnection()->getRowCount("tracks"), "Wrong row count"); - $this->assertEquals(2, $this->getConnection()->getRowCount("positions"), "Wrong row count"); + self::assertEquals(1, $this->getConnection()->getRowCount("tracks"), "Wrong row count"); + self::assertEquals(2, $this->getConnection()->getRowCount("positions"), "Wrong row count"); $expected = [ "id" => 1, @@ -507,12 +520,15 @@ class ImportTest extends UloggerAPITestCase { $this->assertTableContains($expected, $actual, "Wrong actual table data"); } - public function testImportMultipleTracks() { + /** + * @throws GuzzleException + */ + public function testImportMultipleTracks(): void { - $this->assertTrue($this->authenticate(), "Authentication failed"); + self::assertTrue($this->authenticate(), "Authentication failed"); - $this->assertEquals(0, $this->getConnection()->getRowCount("tracks"), "Wrong row count"); - $this->assertEquals(0, $this->getConnection()->getRowCount("positions"), "Wrong row count"); + self::assertEquals(0, $this->getConnection()->getRowCount("tracks"), "Wrong row count"); + self::assertEquals(0, $this->getConnection()->getRowCount("positions"), "Wrong row count"); $gpx = ' http->post("/utils/import.php", $options); - $this->assertEquals(200, $response->getStatusCode(), "Unexpected status code"); + self::assertEquals(200, $response->getStatusCode(), "Unexpected status code"); $json = json_decode($response->getBody()); - $this->assertNotNull($json, "JSON object is null"); - $this->assertEquals(count($json), 2, "Wrong count of tracks"); + self::assertNotNull($json, "JSON object is null"); + self::assertCount(2, $json, "Wrong count of tracks"); $track = $json[0]; - $this->assertEquals(2, (int) $track->id, "Wrong track id"); - $this->assertEquals($this->testTrackName, $track->name, "Wrong track name"); + self::assertEquals(2, (int) $track->id, "Wrong track id"); + self::assertEquals($this->testTrackName, $track->name, "Wrong track name"); $track = $json[1]; - $this->assertEquals(1, (int) $track->id, "Wrong track id"); - $this->assertEquals($this->testTrackName, $track->name, "Wrong track name"); + self::assertEquals(1, (int) $track->id, "Wrong track id"); + self::assertEquals($this->testTrackName, $track->name, "Wrong track name"); - $this->assertEquals(2, $this->getConnection()->getRowCount("tracks"), "Wrong row count"); - $this->assertEquals(2, $this->getConnection()->getRowCount("positions"), "Wrong row count"); + self::assertEquals(2, $this->getConnection()->getRowCount("tracks"), "Wrong row count"); + self::assertEquals(2, $this->getConnection()->getRowCount("positions"), "Wrong row count"); $expected = [ "id" => 1, @@ -625,16 +641,18 @@ class ImportTest extends UloggerAPITestCase { $this->assertTableContains($expected, $actual, "Wrong actual table data"); } - public function testImportNoLongitude() { + /** + * @throws GuzzleException + */ + public function testImportNoLongitude(): void { $lang = (new uLang($this->mockConfig))->getStrings(); - $this->assertTrue($this->authenticate(), "Authentication failed"); + self::assertTrue($this->authenticate(), "Authentication failed"); - $this->assertEquals(0, $this->getConnection()->getRowCount("tracks"), "Wrong row count"); - $this->assertEquals(0, $this->getConnection()->getRowCount("positions"), "Wrong row count"); + self::assertEquals(0, $this->getConnection()->getRowCount("tracks"), "Wrong row count"); + self::assertEquals(0, $this->getConnection()->getRowCount("positions"), "Wrong row count"); $gpx = ' - @@ -660,28 +678,30 @@ class ImportTest extends UloggerAPITestCase { ], ]; $response = $this->http->post("/utils/import.php", $options); - $this->assertEquals(200, $response->getStatusCode(), "Unexpected status code"); + self::assertEquals(200, $response->getStatusCode(), "Unexpected status code"); $json = json_decode($response->getBody()); - $this->assertNotNull($json, "JSON object is null"); - $this->assertEquals(1, (int) $json->error, "Wrong error status"); - $this->assertEquals($lang["iparsefailure"], (string) $json->message, "Wrong error status"); + self::assertNotNull($json, "JSON object is null"); + self::assertEquals(1, (int) $json->error, "Wrong error status"); + self::assertEquals($lang["iparsefailure"], (string) $json->message, "Wrong error status"); - $this->assertEquals(0, $this->getConnection()->getRowCount("tracks"), "Wrong row count"); - $this->assertEquals(0, $this->getConnection()->getRowCount("positions"), "Wrong row count"); + self::assertEquals(0, $this->getConnection()->getRowCount("tracks"), "Wrong row count"); + self::assertEquals(0, $this->getConnection()->getRowCount("positions"), "Wrong row count"); } - public function testImportNoLatitude() { + /** + * @throws GuzzleException + */ + public function testImportNoLatitude(): void { $lang = (new uLang($this->mockConfig))->getStrings(); - $this->assertTrue($this->authenticate(), "Authentication failed"); + self::assertTrue($this->authenticate(), "Authentication failed"); - $this->assertEquals(0, $this->getConnection()->getRowCount("tracks"), "Wrong row count"); - $this->assertEquals(0, $this->getConnection()->getRowCount("positions"), "Wrong row count"); + self::assertEquals(0, $this->getConnection()->getRowCount("tracks"), "Wrong row count"); + self::assertEquals(0, $this->getConnection()->getRowCount("positions"), "Wrong row count"); $gpx = ' - @@ -707,24 +727,27 @@ class ImportTest extends UloggerAPITestCase { ], ]; $response = $this->http->post("/utils/import.php", $options); - $this->assertEquals(200, $response->getStatusCode(), "Unexpected status code"); + self::assertEquals(200, $response->getStatusCode(), "Unexpected status code"); $json = json_decode($response->getBody()); - $this->assertNotNull($json, "JSON object is null"); - $this->assertEquals(1, (int) $json->error, "Wrong error status"); - $this->assertEquals($lang["iparsefailure"], (string) $json->message, "Wrong error status"); + self::assertNotNull($json, "JSON object is null"); + self::assertEquals(1, (int) $json->error, "Wrong error status"); + self::assertEquals($lang["iparsefailure"], (string) $json->message, "Wrong error status"); - $this->assertEquals(0, $this->getConnection()->getRowCount("tracks"), "Wrong row count"); - $this->assertEquals(0, $this->getConnection()->getRowCount("positions"), "Wrong row count"); + self::assertEquals(0, $this->getConnection()->getRowCount("tracks"), "Wrong row count"); + self::assertEquals(0, $this->getConnection()->getRowCount("positions"), "Wrong row count"); } - public function testImportNoGPX() { + /** + * @throws GuzzleException + */ + public function testImportNoGPX(): void { $lang = (new uLang($this->mockConfig))->getStrings(); - $this->assertTrue($this->authenticate(), "Authentication failed"); + self::assertTrue($this->authenticate(), "Authentication failed"); - $this->assertEquals(0, $this->getConnection()->getRowCount("tracks"), "Wrong row count"); - $this->assertEquals(0, $this->getConnection()->getRowCount("positions"), "Wrong row count"); + self::assertEquals(0, $this->getConnection()->getRowCount("tracks"), "Wrong row count"); + self::assertEquals(0, $this->getConnection()->getRowCount("positions"), "Wrong row count"); $gpx = ' @@ -748,28 +771,30 @@ class ImportTest extends UloggerAPITestCase { ], ]; $response = $this->http->post("/utils/import.php", $options); - $this->assertEquals(200, $response->getStatusCode(), "Unexpected status code"); + self::assertEquals(200, $response->getStatusCode(), "Unexpected status code"); $json = json_decode($response->getBody()); - $this->assertNotNull($json, "JSON object is null"); - $this->assertEquals(1, (int) $json->error, "Wrong error status"); - $this->assertEquals($lang["iparsefailure"], (string) $json->message, "Wrong error status"); + self::assertNotNull($json, "JSON object is null"); + self::assertEquals(1, (int) $json->error, "Wrong error status"); + self::assertEquals($lang["iparsefailure"], (string) $json->message, "Wrong error status"); - $this->assertEquals(0, $this->getConnection()->getRowCount("tracks"), "Wrong row count"); - $this->assertEquals(0, $this->getConnection()->getRowCount("positions"), "Wrong row count"); + self::assertEquals(0, $this->getConnection()->getRowCount("tracks"), "Wrong row count"); + self::assertEquals(0, $this->getConnection()->getRowCount("positions"), "Wrong row count"); } - public function testImportCorrupt() { + /** + * @throws GuzzleException + */ + public function testImportCorrupt(): void { $lang = (new uLang($this->mockConfig))->getStrings(); - $this->assertTrue($this->authenticate(), "Authentication failed"); + self::assertTrue($this->authenticate(), "Authentication failed"); - $this->assertEquals(0, $this->getConnection()->getRowCount("tracks"), "Wrong row count"); - $this->assertEquals(0, $this->getConnection()->getRowCount("positions"), "Wrong row count"); + self::assertEquals(0, $this->getConnection()->getRowCount("tracks"), "Wrong row count"); + self::assertEquals(0, $this->getConnection()->getRowCount("positions"), "Wrong row count"); $gpx = ' - @@ -793,16 +818,16 @@ class ImportTest extends UloggerAPITestCase { ], ]; $response = $this->http->post("/utils/import.php", $options); - $this->assertEquals(200, $response->getStatusCode(), "Unexpected status code"); + self::assertEquals(200, $response->getStatusCode(), "Unexpected status code"); $json = json_decode($response->getBody()); - $this->assertNotNull($json, "JSON object is null"); - $this->assertEquals(1, (int) $json->error, "Wrong error status"); - $this->assertEquals(0, strpos((string) $json->message, $lang["iparsefailure"]), "Wrong error status"); + self::assertNotNull($json, "JSON object is null"); + self::assertEquals(1, (int) $json->error, "Wrong error status"); + self::assertEquals(0, strpos((string) $json->message, $lang["iparsefailure"]), "Wrong error status"); - $this->assertEquals(0, $this->getConnection()->getRowCount("tracks"), "Wrong row count"); - $this->assertEquals(0, $this->getConnection()->getRowCount("positions"), "Wrong row count"); + self::assertEquals(0, $this->getConnection()->getRowCount("tracks"), "Wrong row count"); + self::assertEquals(0, $this->getConnection()->getRowCount("positions"), "Wrong row count"); } private function getStream($string) { diff --git a/.tests/tests/InternalAPITest.php b/.tests/tests/InternalAPITest.php index e864cec..e6971f1 100644 --- a/.tests/tests/InternalAPITest.php +++ b/.tests/tests/InternalAPITest.php @@ -1,5 +1,7 @@ authenticate(), "Authentication failed"); @@ -47,7 +52,10 @@ class InternalAPITest extends UloggerAPITestCase { self::assertEquals($this->testTrackName, (string) $position->trackname,"Wrong trackname"); } - public function testGetPositionsUser() { + /** + * @throws GuzzleException + */ + public function testGetPositionsUser(): void { $userId = $this->addTestUser($this->testUser, password_hash($this->testPass, PASSWORD_DEFAULT)); self::assertEquals(2, $this->getConnection()->getRowCount("users"), "Wrong row count"); self::assertTrue($this->authenticate($this->testUser, $this->testPass), "Authentication failed"); @@ -86,7 +94,10 @@ class InternalAPITest extends UloggerAPITestCase { self::assertEquals($this->testTrackName, (string) $position->trackname,"Wrong trackname"); } - public function testGetPositionsOtherUser() { + /** + * @throws GuzzleException + */ + public function testGetPositionsOtherUser(): void { $userId = $this->addTestUser($this->testUser, password_hash($this->testPass, PASSWORD_DEFAULT)); self::assertEquals(2, $userId); self::assertEquals(2, $this->getConnection()->getRowCount("users"), "Wrong row count"); @@ -110,7 +121,10 @@ class InternalAPITest extends UloggerAPITestCase { self::assertCount(0, $json, "Wrong count of positions"); } - public function testGetPositionsOtherUserByAdmin() { + /** + * @throws GuzzleException + */ + public function testGetPositionsOtherUserByAdmin(): void { $userId = $this->addTestUser($this->testUser, password_hash($this->testPass, PASSWORD_DEFAULT)); self::assertEquals(2, $userId); self::assertEquals(2, $this->getConnection()->getRowCount("users"), "Wrong row count"); @@ -150,7 +164,10 @@ class InternalAPITest extends UloggerAPITestCase { self::assertEquals($this->testTrackName, (string) $position->trackname,"Wrong trackname"); } - public function testGetPositionsUserLatest() { + /** + * @throws GuzzleException + */ + public function testGetPositionsUserLatest(): void { self::assertTrue($this->authenticate(), "Authentication failed"); $trackId = $this->addTestTrack($this->testUserId); @@ -186,7 +203,10 @@ class InternalAPITest extends UloggerAPITestCase { self::assertEquals($this->testTrackName, (string) $position->trackname,"Wrong trackname"); } - public function testGetPositionsAllUsersLatest() { + /** + * @throws GuzzleException + */ + public function testGetPositionsAllUsersLatest(): void { self::assertTrue($this->authenticate(), "Authentication failed"); $userId = $this->addTestUser($this->testUser, password_hash($this->testPass, PASSWORD_DEFAULT)); @@ -231,7 +251,10 @@ class InternalAPITest extends UloggerAPITestCase { self::assertEquals($trackName, (string) $position->trackname,"Wrong trackname"); } - public function testGetPositionsNoTrackId() { + /** + * @throws GuzzleException + */ + public function testGetPositionsNoTrackId(): void { self::assertTrue($this->authenticate(), "Authentication failed"); @@ -253,7 +276,10 @@ class InternalAPITest extends UloggerAPITestCase { self::assertCount(0, $json, "Wrong count of positions"); } - public function testGetPositionsNoUserId() { + /** + * @throws GuzzleException + */ + public function testGetPositionsNoUserId(): void { self::assertTrue($this->authenticate(), "Authentication failed"); @@ -275,7 +301,10 @@ class InternalAPITest extends UloggerAPITestCase { self::assertCount(0, $json, "Wrong count of positions"); } - public function testGetPositionsNoAuth() { + /** + * @throws GuzzleException + */ + public function testGetPositionsNoAuth(): void { $trackId = $this->addTestTrack($this->testUserId); $this->addTestPosition($this->testUserId, $trackId, $this->testTimestamp); @@ -294,7 +323,10 @@ class InternalAPITest extends UloggerAPITestCase { self::assertCount(0, $json, "Wrong count of positions"); } - public function testGetPositionsAfterId() { + /** + * @throws GuzzleException + */ + public function testGetPositionsAfterId(): void { self::assertTrue($this->authenticate(), "Authentication failed"); @@ -331,7 +363,10 @@ class InternalAPITest extends UloggerAPITestCase { /* gettracks.php */ - public function testGetTracksAdmin() { + /** + * @throws GuzzleException + */ + public function testGetTracksAdmin(): void { self::assertTrue($this->authenticate(), "Authentication failed"); @@ -360,7 +395,10 @@ class InternalAPITest extends UloggerAPITestCase { self::assertEquals($this->testTrackName, (string) $track->name,"Wrong track name"); } - public function testGetTracksUser() { + /** + * @throws GuzzleException + */ + public function testGetTracksUser(): void { $userId = $this->addTestUser($this->testUser, password_hash($this->testPass, PASSWORD_DEFAULT)); self::assertEquals(2, $this->getConnection()->getRowCount("users"), "Wrong row count"); self::assertTrue($this->authenticate($this->testUser, $this->testPass), "Authentication failed"); @@ -390,7 +428,10 @@ class InternalAPITest extends UloggerAPITestCase { self::assertEquals($this->testTrackName, (string) $track->name,"Wrong track name"); } - public function testGetTracksOtherUser() { + /** + * @throws GuzzleException + */ + public function testGetTracksOtherUser(): void { $this->addTestUser($this->testUser, password_hash($this->testPass, PASSWORD_DEFAULT)); self::assertEquals(2, $this->getConnection()->getRowCount("users"), "Wrong row count"); self::assertTrue($this->authenticate($this->testUser, $this->testPass), "Authentication failed"); @@ -412,7 +453,10 @@ class InternalAPITest extends UloggerAPITestCase { self::assertCount(0, $json, "Wrong count of tracks"); } - public function testGetTracksNoUserId() { + /** + * @throws GuzzleException + */ + public function testGetTracksNoUserId(): void { $this->addTestUser($this->testUser, password_hash($this->testPass, PASSWORD_DEFAULT)); self::assertEquals(2, $this->getConnection()->getRowCount("users"), "Wrong row count"); self::assertTrue($this->authenticate($this->testUser, $this->testPass), "Authentication failed"); @@ -432,7 +476,10 @@ class InternalAPITest extends UloggerAPITestCase { self::assertCount(0, $json, "Wrong count of tracks"); } - public function testGetTracksNoAuth() { + /** + * @throws GuzzleException + */ + public function testGetTracksNoAuth(): void { $this->addTestTrack($this->testUserId); $this->addTestTrack($this->testUserId, $this->testTrackName . "2"); @@ -454,7 +501,10 @@ class InternalAPITest extends UloggerAPITestCase { /* changepass.php */ - public function testChangePassNoAuth() { + /** + * @throws GuzzleException + */ + public function testChangePassNoAuth(): void { $options = [ "http_errors" => false, @@ -473,7 +523,10 @@ class InternalAPITest extends UloggerAPITestCase { self::assertEquals("User not authorized", (string) $json->message, "Wrong error message"); } - public function testChangePassEmpty() { + /** + * @throws GuzzleException + */ + public function testChangePassEmpty(): void { self::assertTrue($this->authenticate(), "Authentication failed"); $options = [ @@ -489,7 +542,10 @@ class InternalAPITest extends UloggerAPITestCase { self::assertEquals("Empty password", (string) $json->message, "Wrong error message"); } - public function testChangePassUserUnknown() { + /** + * @throws GuzzleException + */ + public function testChangePassUserUnknown(): void { self::assertTrue($this->authenticate(), "Authentication failed"); $options = [ @@ -508,7 +564,10 @@ class InternalAPITest extends UloggerAPITestCase { self::assertEquals("User unknown", (string) $json->message, "Wrong error message"); } - public function testChangePassEmptyLogin() { + /** + * @throws GuzzleException + */ + public function testChangePassEmptyLogin(): void { self::assertTrue($this->authenticate(), "Authentication failed"); $options = [ @@ -526,7 +585,10 @@ class InternalAPITest extends UloggerAPITestCase { self::assertEquals("Empty login", (string) $json->message, "Wrong error message"); } - public function testChangePassWrongOldpass() { + /** + * @throws GuzzleException + */ + public function testChangePassWrongOldpass(): void { self::assertTrue($this->authenticate(), "Authentication failed"); $options = [ @@ -546,7 +608,10 @@ class InternalAPITest extends UloggerAPITestCase { self::assertEquals("Wrong old password", (string) $json->message, "Wrong error message"); } - public function testChangePassNoOldpass() { + /** + * @throws GuzzleException + */ + public function testChangePassNoOldpass(): void { self::assertTrue($this->authenticate(), "Authentication failed"); $options = [ @@ -565,7 +630,10 @@ class InternalAPITest extends UloggerAPITestCase { self::assertEquals("Wrong old password", (string) $json->message,"Wrong error message"); } - public function testChangePassSelfAdmin() { + /** + * @throws GuzzleException + */ + public function testChangePassSelfAdmin(): void { self::assertTrue($this->authenticate(), "Authentication failed"); $newPass = "Newpass1234567890"; @@ -586,7 +654,10 @@ class InternalAPITest extends UloggerAPITestCase { self::assertTrue(password_verify($newPass, $this->pdoGetColumn("SELECT password FROM users")), "Wrong actual password hash"); } - public function testChangePassSelfUser() { + /** + * @throws GuzzleException + */ + public function testChangePassSelfUser(): void { $userId = $this->addTestUser($this->testUser, password_hash($this->testPass, PASSWORD_DEFAULT)); self::assertTrue($this->authenticate($this->testUser, $this->testPass), "Authentication failed"); @@ -608,7 +679,10 @@ class InternalAPITest extends UloggerAPITestCase { self::assertTrue(password_verify($newPass, $this->pdoGetColumn("SELECT password FROM users WHERE id = $userId")), "Wrong actual password hash"); } - public function testChangePassOtherAdmin() { + /** + * @throws GuzzleException + */ + public function testChangePassOtherAdmin(): void { self::assertTrue($this->authenticate(), "Authentication failed"); $userId = $this->addTestUser($this->testUser, password_hash($this->testPass, PASSWORD_DEFAULT)); @@ -629,7 +703,10 @@ class InternalAPITest extends UloggerAPITestCase { self::assertTrue(password_verify($newPass, $this->pdoGetColumn("SELECT password FROM users WHERE id = $userId")), "Wrong actual password hash"); } - public function testChangePassOtherUser() { + /** + * @throws GuzzleException + */ + public function testChangePassOtherUser(): void { $this->addTestUser($this->testUser, password_hash($this->testPass, PASSWORD_DEFAULT)); $this->addTestUser($this->testUser2, password_hash($this->testPass, PASSWORD_DEFAULT)); self::assertTrue($this->authenticate($this->testUser, $this->testPass), "Authentication failed"); @@ -654,7 +731,10 @@ class InternalAPITest extends UloggerAPITestCase { /* handletrack.php */ - public function testHandleTrackDeleteAdmin() { + /** + * @throws GuzzleException + */ + public function testHandleTrackDeleteAdmin(): void { self::assertTrue($this->authenticate(), "Authentication failed"); $userId = $this->addTestUser($this->testUser, password_hash($this->testPass, PASSWORD_DEFAULT)); self::assertEquals(2, $this->getConnection()->getRowCount("users"), "Wrong row count"); @@ -676,7 +756,10 @@ class InternalAPITest extends UloggerAPITestCase { self::assertEquals($trackId2, $this->pdoGetColumn("SELECT id FROM tracks WHERE id = $trackId2"), "Wrong actual track id"); } - public function testHandleTrackDeleteSelf() { + /** + * @throws GuzzleException + */ + public function testHandleTrackDeleteSelf(): void { $userId = $this->addTestUser($this->testUser, password_hash($this->testPass, PASSWORD_DEFAULT)); self::assertEquals(2, $this->getConnection()->getRowCount("users"), "Wrong row count"); self::assertTrue($this->authenticate($this->testUser, $this->testPass), "Authentication failed"); @@ -698,7 +781,10 @@ class InternalAPITest extends UloggerAPITestCase { self::assertEquals($trackId2, $this->pdoGetColumn("SELECT id FROM tracks WHERE id = $trackId2"), "Wrong actual track id"); } - public function testHandleTrackDeleteOtherUser() { + /** + * @throws GuzzleException + */ + public function testHandleTrackDeleteOtherUser(): void { $lang = (new uLang($this->mockConfig))->getStrings(); $this->addTestUser($this->testUser, password_hash($this->testPass, PASSWORD_DEFAULT)); self::assertEquals(2, $this->getConnection()->getRowCount("users"), "Wrong row count"); @@ -720,7 +806,10 @@ class InternalAPITest extends UloggerAPITestCase { self::assertEquals($lang["notauthorized"], (string) $json->message, "Wrong error message"); } - public function testHandleTrackUpdate() { + /** + * @throws GuzzleException + */ + public function testHandleTrackUpdate(): void { $newName = "New name"; self::assertTrue($this->authenticate(), "Authentication failed"); $userId = $this->addTestUser($this->testUser, password_hash($this->testPass, PASSWORD_DEFAULT)); @@ -760,7 +849,10 @@ class InternalAPITest extends UloggerAPITestCase { $this->assertTableContains($row2, $actual, "Wrong actual table data"); } - public function testHandleTrackUpdateEmptyName() { + /** + * @throws GuzzleException + */ + public function testHandleTrackUpdateEmptyName(): void { $lang = (new uLang($this->mockConfig))->getStrings(); self::assertTrue($this->authenticate(), "Authentication failed"); $userId = $this->addTestUser($this->testUser, password_hash($this->testPass, PASSWORD_DEFAULT)); @@ -784,7 +876,10 @@ class InternalAPITest extends UloggerAPITestCase { self::assertEquals(2, $this->getConnection()->getRowCount("tracks"), "Wrong row count"); } - public function testHandleTrackUpdateNonexistantTrack() { + /** + * @throws GuzzleException + */ + public function testHandleTrackUpdateNonexistantTrack(): void { $lang = (new uLang($this->mockConfig))->getStrings(); $newName = "New name"; self::assertTrue($this->authenticate(), "Authentication failed"); @@ -808,7 +903,10 @@ class InternalAPITest extends UloggerAPITestCase { self::assertEquals($lang["servererror"], (string) $json->message,"Wrong error message"); } - public function testHandleTrackMissingAction() { + /** + * @throws GuzzleException + */ + public function testHandleTrackMissingAction(): void { $lang = (new uLang($this->mockConfig))->getStrings(); self::assertTrue($this->authenticate(), "Authentication failed"); @@ -826,7 +924,10 @@ class InternalAPITest extends UloggerAPITestCase { /* handleuser.php */ - public function testHandleUserMissingAction() { + /** + * @throws GuzzleException + */ + public function testHandleUserMissingAction(): void { $lang = (new uLang($this->mockConfig))->getStrings(); self::assertTrue($this->authenticate(), "Authentication failed"); @@ -841,7 +942,10 @@ class InternalAPITest extends UloggerAPITestCase { self::assertEquals($lang["servererror"], (string) $json->message,"Wrong error message"); } - public function testHandleUserNonAdmin() { + /** + * @throws GuzzleException + */ + public function testHandleUserNonAdmin(): void { $lang = (new uLang($this->mockConfig))->getStrings(); $this->addTestUser($this->testUser, password_hash($this->testPass, PASSWORD_DEFAULT)); self::assertEquals(2, $this->getConnection()->getRowCount("users"), "Wrong row count"); @@ -861,7 +965,10 @@ class InternalAPITest extends UloggerAPITestCase { } - public function testHandleUserSelf() { + /** + * @throws GuzzleException + */ + public function testHandleUserSelf(): void { $lang = (new uLang($this->mockConfig))->getStrings(); self::assertTrue($this->authenticate(), "Authentication failed"); self::assertEquals(1, $this->getConnection()->getRowCount("users"), "Wrong row count"); @@ -879,7 +986,10 @@ class InternalAPITest extends UloggerAPITestCase { self::assertEquals(1, $this->getConnection()->getRowCount("users"), "Wrong row count"); } - public function testHandleUserEmptyLogin() { + /** + * @throws GuzzleException + */ + public function testHandleUserEmptyLogin(): void { $lang = (new uLang($this->mockConfig))->getStrings(); self::assertTrue($this->authenticate(), "Authentication failed"); self::assertEquals(1, $this->getConnection()->getRowCount("users"), "Wrong row count"); @@ -897,7 +1007,10 @@ class InternalAPITest extends UloggerAPITestCase { self::assertEquals(1, $this->getConnection()->getRowCount("users"), "Wrong row count"); } - public function testHandleUserNoAuth() { + /** + * @throws GuzzleException + */ + public function testHandleUserNoAuth(): void { $lang = (new uLang($this->mockConfig))->getStrings(); $this->addTestUser($this->testUser, password_hash($this->testPass, PASSWORD_DEFAULT)); self::assertEquals(2, $this->getConnection()->getRowCount("users"), "Wrong row count"); @@ -916,7 +1029,10 @@ class InternalAPITest extends UloggerAPITestCase { self::assertEquals(2, $this->getConnection()->getRowCount("users"), "Wrong row count"); } - public function testHandleUserAdd() { + /** + * @throws GuzzleException + */ + public function testHandleUserAdd(): void { self::assertTrue($this->authenticate(), "Authentication failed"); self::assertEquals(1, $this->getConnection()->getRowCount("users"), "Wrong row count"); @@ -940,7 +1056,10 @@ class InternalAPITest extends UloggerAPITestCase { self::assertTrue(password_verify($this->testPass, $this->pdoGetColumn("SELECT password FROM users WHERE login = '$this->testUser'")), "Wrong actual password hash"); } - public function testHandleUserAddSameLogin() { + /** + * @throws GuzzleException + */ + public function testHandleUserAddSameLogin(): void { $lang = (new uLang($this->mockConfig))->getStrings(); self::assertTrue($this->authenticate(), "Authentication failed"); $this->addTestUser($this->testUser, password_hash($this->testPass, PASSWORD_DEFAULT)); @@ -959,7 +1078,10 @@ class InternalAPITest extends UloggerAPITestCase { self::assertEquals(2, $this->getConnection()->getRowCount("users"), "Wrong row count"); } - public function testHandleUserUpdate() { + /** + * @throws GuzzleException + */ + public function testHandleUserUpdate(): void { $newPass = $this->testPass . "new"; self::assertTrue($this->authenticate(), "Authentication failed"); $this->addTestUser($this->testUser, password_hash($this->testPass, PASSWORD_DEFAULT)); @@ -977,7 +1099,10 @@ class InternalAPITest extends UloggerAPITestCase { self::assertTrue(password_verify($newPass, $this->pdoGetColumn("SELECT password FROM users WHERE login = '$this->testUser'")), "Wrong actual password hash"); } - public function testHandleUserUpdateEmptyPass() { + /** + * @throws GuzzleException + */ + public function testHandleUserUpdateEmptyPass(): void { self::assertTrue($this->authenticate(), "Authentication failed"); $this->addTestUser($this->testUser, password_hash($this->testPass, PASSWORD_DEFAULT)); self::assertEquals(2, $this->getConnection()->getRowCount("users"), "Wrong row count"); @@ -993,7 +1118,10 @@ class InternalAPITest extends UloggerAPITestCase { self::assertTrue(password_verify($this->testPass, $this->pdoGetColumn("SELECT password FROM users WHERE login = '$this->testUser'")), "Wrong actual password hash"); } - public function testHandleUserDelete() { + /** + * @throws GuzzleException + */ + public function testHandleUserDelete(): void { self::assertTrue($this->authenticate(), "Authentication failed"); $this->addTestUser($this->testUser, password_hash($this->testPass, PASSWORD_DEFAULT)); self::assertEquals(2, $this->getConnection()->getRowCount("users"), "Wrong row count"); diff --git a/.tests/tests/LangTest.php b/.tests/tests/LangTest.php index ba2fdee..c2a3cb0 100644 --- a/.tests/tests/LangTest.php +++ b/.tests/tests/LangTest.php @@ -10,34 +10,34 @@ class LangTest extends TestCase { protected $mockConfig; - public function setUp() { + public function setUp(): void { parent::setUp(); $this->mockConfig = new uConfig(false); } - public function testGetLanguages() { + public function testGetLanguages(): void { $languages = uLang::getLanguages(); - $this->assertNotEmpty($languages); - $this->assertArrayHasKey("en", $languages); - $this->assertArrayHasKey("pl", $languages); - $this->assertEquals("English", $languages["en"]); - $this->assertEquals("Polski", $languages["pl"]); + self::assertNotEmpty($languages); + self::assertArrayHasKey("en", $languages); + self::assertArrayHasKey("pl", $languages); + self::assertEquals("English", $languages["en"]); + self::assertEquals("Polski", $languages["pl"]); } - public function testGetStrings() { + public function testGetStrings(): void { $lang = new uLang($this->mockConfig); - $this->assertEquals("User", $lang->getStrings()["user"]); + self::assertEquals("User", $lang->getStrings()["user"]); $this->mockConfig->lang = "pl"; $lang = new uLang($this->mockConfig); - $this->assertEquals("Użytkownik", $lang->getStrings()["user"]); + self::assertEquals("Użytkownik", $lang->getStrings()["user"]); } - public function testGetSetupStrings() { + public function testGetSetupStrings(): void { $lang = new uLang($this->mockConfig); - $this->assertEquals("Congratulations!", $lang->getSetupStrings()["congratulations"]); + self::assertEquals("Congratulations!", $lang->getSetupStrings()["congratulations"]); $this->mockConfig->lang = "pl"; $lang = new uLang($this->mockConfig); - $this->assertEquals("Gratulacje!", $lang->getSetupStrings()["congratulations"]); + self::assertEquals("Gratulacje!", $lang->getSetupStrings()["congratulations"]); } } ?> diff --git a/.tests/tests/MigrateTest.php b/.tests/tests/MigrateTest.php index ebf38dd..8f24dc1 100644 --- a/.tests/tests/MigrateTest.php +++ b/.tests/tests/MigrateTest.php @@ -24,42 +24,42 @@ require_once(dirname(__DIR__) . "/lib/UloggerDatabaseTestCase.php"); class MigrateTest extends UloggerDatabaseTestCase { - protected function tearDown() { + protected function tearDown(): void { if ($this->getName() === "testUpdateSchemas") { self::runSqlScript(dirname(__DIR__) . "/../scripts/ulogger." . $this->getDbDriverName()); } parent::tearDown(); } - public function testUpdateSchemas() { + public function testUpdateSchemas(): void { self::runSqlScript(dirname(__DIR__) . "/fixtures/ulogger_0_6." . $this->getDbDriverName()); $this->loadDataSet("fixture_0_6.xml"); - $this->assertEquals(1, $this->getConnection()->getRowCount("users"), "Wrong row count"); - $this->assertNotContains("admin", $this->getConnection()->getMetaData()->getTableColumns("users")); - $this->assertContains("image_id", $this->getConnection()->getMetaData()->getTableColumns("positions")); - $this->assertNotContains("ol_layers", $this->getConnection()->getMetaData()->getTableNames()); - $this->assertNotContains("config", $this->getConnection()->getMetaData()->getTableNames()); + self::assertEquals(1, $this->getConnection()->getRowCount("users"), "Wrong row count"); + self::assertNotContains("admin", $this->getConnection()->getMetaData()->getTableColumns("users")); + self::assertContains("image_id", $this->getConnection()->getMetaData()->getTableColumns("positions")); + self::assertNotContains("ol_layers", $this->getConnection()->getMetaData()->getTableNames()); + self::assertNotContains("config", $this->getConnection()->getMetaData()->getTableNames()); $this->setOutputCallback(static function() {}); $ret = updateSchemas(); $this->resetConnection(); - $this->assertTrue($ret, "Function updateSchemas() failed"); - $this->assertEquals(1, $this->getConnection()->getRowCount("users"), "Wrong row count"); - $this->assertEquals(1, $this->getConnection()->getRowCount("tracks"), "Wrong row count"); - $this->assertEquals(1, $this->getConnection()->getRowCount("positions"), "Wrong row count"); - $this->assertContains("admin", $this->getConnection()->getMetaData()->getTableColumns("users"), "Missing table column"); - $this->assertContains("image", $this->getConnection()->getMetaData()->getTableColumns("positions"), "Missing table column"); - $this->assertContains("ol_layers", $this->getConnection()->getMetaData()->getTableNames(), "Missing table"); - $this->assertContains("config", $this->getConnection()->getMetaData()->getTableNames(), "Missing table"); + self::assertTrue($ret, "Function updateSchemas() failed"); + self::assertEquals(1, $this->getConnection()->getRowCount("users"), "Wrong row count"); + self::assertEquals(1, $this->getConnection()->getRowCount("tracks"), "Wrong row count"); + self::assertEquals(1, $this->getConnection()->getRowCount("positions"), "Wrong row count"); + self::assertContains("admin", $this->getConnection()->getMetaData()->getTableColumns("users"), "Missing table column"); + self::assertContains("image", $this->getConnection()->getMetaData()->getTableColumns("positions"), "Missing table column"); + self::assertContains("ol_layers", $this->getConnection()->getMetaData()->getTableNames(), "Missing table"); + self::assertContains("config", $this->getConnection()->getMetaData()->getTableNames(), "Missing table"); } - public function testUpdateConfig() { + public function testUpdateConfig(): void { $this->loadDataSet("fixture_non_admin.xml"); $this->setOutputCallback(static function() {}); $ret = updateConfig(dirname(__DIR__) . "/fixtures/config_0_6.php"); - $this->assertTrue($ret, "Function updateConfig() failed"); + self::assertTrue($ret, "Function updateConfig() failed"); // admin user imported from config file - $this->assertEquals(1, $this->getConnection()->getRowCount("users"), "Wrong row count"); - $this->assertTrue((bool) $this->pdoGetColumn("SELECT admin FROM users WHERE login = 'admin'"), "User should be admin"); + self::assertEquals(1, $this->getConnection()->getRowCount("users"), "Wrong row count"); + self::assertTrue((bool) $this->pdoGetColumn("SELECT admin FROM users WHERE login = 'admin'"), "User should be admin"); // settings imported from config file $expected = [ "config" => [ ["name" => "color_extra", "value" => "s:7:\"#cccccc\";"], // default @@ -90,7 +90,7 @@ class MigrateTest extends UloggerDatabaseTestCase { $expected = $this->createArrayDataSet($expected)->getTable("config"); self::assertTablesEqual($expected, $actual); // layers imported from config file - $this->assertEquals(1, $this->getConnection()->getRowCount("ol_layers"), "Wrong row count"); + self::assertEquals(1, $this->getConnection()->getRowCount("ol_layers"), "Wrong row count"); $expected = [ "id" => 1, "name" => "TestLayer", "url" => "https://test_tile.png", "priority" => 0 ]; $actual = $this->getConnection()->createQueryTable( "ol_layers", @@ -99,19 +99,19 @@ class MigrateTest extends UloggerDatabaseTestCase { $this->assertTableContains($expected, $actual, "Wrong actual table data"); } - public function testWaitForUser() { + public function testWaitForUser(): void { $this->setOutputCallback(static function() {}); $yes = tmpfile(); fwrite($yes, "yes"); $ret = waitForUser(stream_get_meta_data($yes)['uri']); fclose($yes); - $this->assertTrue($ret, "Wrong return status"); + self::assertTrue($ret, "Wrong return status"); $no = tmpfile(); fwrite($no, "no"); $ret = waitForUser(stream_get_meta_data($no)['uri']); fclose($no); - $this->assertFalse($ret, "Wrong return status"); + self::assertFalse($ret, "Wrong return status"); } /** @@ -120,7 +120,7 @@ class MigrateTest extends UloggerDatabaseTestCase { * @param string $path Script path * @throws PDOException */ - private static function runSqlScript($path) { + private static function runSqlScript(string $path): void { $script = file_get_contents($path); $count = preg_match_all('/^(?:(?:DROP|CREATE) (?:TABLE|INDEX)|INSERT|PRAGMA|SET) .*?;\s*$/smi', $script, $queries); if ($count) { @@ -146,7 +146,7 @@ class MigrateTest extends UloggerDatabaseTestCase { return uDb::getInstance()->getAttribute(PDO::ATTR_DRIVER_NAME); } - private function loadDataSet($name) { + private function loadDataSet($name): void { $this->resetAutoincrement(); $dataSet = $this->createFlatXMLDataSet(dirname(__DIR__) . '/fixtures/' . $name); $this->getDatabaseTester()->setDataSet($dataSet); diff --git a/.tests/tests/PositionTest.php b/.tests/tests/PositionTest.php index f13c577..c7f7a53 100644 --- a/.tests/tests/PositionTest.php +++ b/.tests/tests/PositionTest.php @@ -5,21 +5,21 @@ require_once(__DIR__ . "/../../helpers/track.php"); class PositionTest extends UloggerDatabaseTestCase { - public function testAddPosition() { + public function testAddPosition(): void { $userId = $this->addTestUser(); $trackId = $this->addTestTrack($userId); - $this->assertEquals(1, $this->getConnection()->getRowCount('tracks'), "Wrong row count"); + self::assertEquals(1, $this->getConnection()->getRowCount('tracks'), "Wrong row count"); $posId = uPosition::add($userId, $trackId + 1, $this->testTimestamp, $this->testLat, $this->testLon, $this->testAltitude, $this->testSpeed, $this->testBearing, $this->testAccuracy, $this->testProvider, $this->testComment, $this->testImage); - $this->assertEquals(0, $this->getConnection()->getRowCount('positions'), "Wrong row count"); - $this->assertFalse($posId, "Adding position with nonexistant track should fail"); + self::assertEquals(0, $this->getConnection()->getRowCount('positions'), "Wrong row count"); + self::assertFalse($posId, "Adding position with nonexistant track should fail"); $posId = uPosition::add($userId + 1, $trackId, $this->testTimestamp, $this->testLat, $this->testLon, $this->testAltitude, $this->testSpeed, $this->testBearing, $this->testAccuracy, $this->testProvider, $this->testComment, $this->testImage); - $this->assertEquals(0, $this->getConnection()->getRowCount('positions'), "Wrong row count"); - $this->assertFalse($posId, "Adding position with wrong user should fail"); + self::assertEquals(0, $this->getConnection()->getRowCount('positions'), "Wrong row count"); + self::assertFalse($posId, "Adding position with wrong user should fail"); $posId = uPosition::add($userId, $trackId, $this->testTimestamp, $this->testLat, $this->testLon, $this->testAltitude, $this->testSpeed, $this->testBearing, $this->testAccuracy, $this->testProvider, $this->testComment, $this->testImage); - $this->assertEquals(1, $this->getConnection()->getRowCount('positions'), "Wrong row count"); + self::assertEquals(1, $this->getConnection()->getRowCount('positions'), "Wrong row count"); $expected = [ "id" => $posId, "user_id" => $this->testUserId, @@ -42,21 +42,21 @@ class PositionTest extends UloggerDatabaseTestCase { $this->assertTableContains($expected, $actual, "Wrong actual table data"); $posId = uPosition::add($userId, $trackId, NULL, $this->testLat, $this->testLon); - $this->assertFalse($posId, "Adding position with null time stamp should fail"); + self::assertFalse($posId, "Adding position with null time stamp should fail"); $posId = uPosition::add($userId, $trackId, $this->testTimestamp, NULL, $this->testLon); - $this->assertFalse($posId, "Adding position with null latitude should fail"); + self::assertFalse($posId, "Adding position with null latitude should fail"); $posId = uPosition::add($userId, $trackId, $this->testTimestamp, $this->testLat, NULL); - $this->assertFalse($posId, "Adding position with null longitude should fail"); + self::assertFalse($posId, "Adding position with null longitude should fail"); $posId = uPosition::add($userId, $trackId, "", $this->testLat, $this->testLon); - $this->assertFalse($posId, "Adding position with empty time stamp should fail"); + self::assertFalse($posId, "Adding position with empty time stamp should fail"); $posId = uPosition::add($userId, $trackId, $this->testTimestamp, "", $this->testLon); - $this->assertFalse($posId, "Adding position with empty latitude should fail"); + self::assertFalse($posId, "Adding position with empty latitude should fail"); $posId = uPosition::add($userId, $trackId, $this->testTimestamp, $this->testLat, ""); - $this->assertFalse($posId, "Adding position with empty longitude should fail"); + self::assertFalse($posId, "Adding position with empty longitude should fail"); } - public function testDeleteAll() { + public function testDeleteAll(): void { $userId = $this->addTestUser(); $userId2 = $this->addTestUser($this->testUser2); $trackId = $this->addTestTrack($userId); @@ -65,14 +65,14 @@ class PositionTest extends UloggerDatabaseTestCase { $this->addTestPosition($userId, $trackId2); $trackId3 = $this->addTestTrack($userId2); $this->addTestPosition($userId2, $trackId3); - $this->assertEquals(3, $this->getConnection()->getRowCount('tracks'), "Wrong row count"); - $this->assertEquals(3, $this->getConnection()->getRowCount('positions'), "Wrong row count"); + self::assertEquals(3, $this->getConnection()->getRowCount('tracks'), "Wrong row count"); + self::assertEquals(3, $this->getConnection()->getRowCount('positions'), "Wrong row count"); - $this->assertTrue(uPosition::deleteAll($userId), "Deleting failed"); - $this->assertEquals(1, $this->getConnection()->getRowCount('positions'), "Wrong row count"); + self::assertTrue(uPosition::deleteAll($userId), "Deleting failed"); + self::assertEquals(1, $this->getConnection()->getRowCount('positions'), "Wrong row count"); } - public function testDeleteAllWIthTrackId() { + public function testDeleteAllWIthTrackId(): void { $userId = $this->addTestUser(); $userId2 = $this->addTestUser($this->testUser2); $trackId = $this->addTestTrack($userId); @@ -81,14 +81,14 @@ class PositionTest extends UloggerDatabaseTestCase { $this->addTestPosition($userId, $trackId2); $trackId3 = $this->addTestTrack($userId2); $this->addTestPosition($userId2, $trackId3); - $this->assertEquals(3, $this->getConnection()->getRowCount('tracks'), "Wrong row count"); - $this->assertEquals(3, $this->getConnection()->getRowCount('positions'), "Wrong row count"); + self::assertEquals(3, $this->getConnection()->getRowCount('tracks'), "Wrong row count"); + self::assertEquals(3, $this->getConnection()->getRowCount('positions'), "Wrong row count"); - $this->assertTrue(uPosition::deleteAll($userId, $trackId), "Deleting failed"); - $this->assertEquals(2, $this->getConnection()->getRowCount('positions'), "Wrong row count"); + self::assertTrue(uPosition::deleteAll($userId, $trackId), "Deleting failed"); + self::assertEquals(2, $this->getConnection()->getRowCount('positions'), "Wrong row count"); } - public function testGetLast() { + public function testGetLast(): void { $userId = $this->addTestUser(); $userId2 = $this->addTestUser($this->testUser2); $trackId1 = $this->addTestTrack($userId); @@ -97,15 +97,15 @@ class PositionTest extends UloggerDatabaseTestCase { $pos2 = $this->addTestPosition($userId2, $trackId2, $this->testTimestamp + 1); $pos3 = $this->addTestPosition($userId, $trackId1, $this->testTimestamp); $pos4 = $this->addTestPosition($userId2, $trackId2, $this->testTimestamp + 2); - $this->assertEquals(2, $this->getConnection()->getRowCount('tracks'), "Wrong row count"); - $this->assertEquals(4, $this->getConnection()->getRowCount('positions'), "Wrong row count"); + self::assertEquals(2, $this->getConnection()->getRowCount('tracks'), "Wrong row count"); + self::assertEquals(4, $this->getConnection()->getRowCount('positions'), "Wrong row count"); $lastPosition = uPosition::getLast(); - $this->assertEquals($lastPosition->id, $pos1, "Wrong last position"); + self::assertEquals($lastPosition->id, $pos1, "Wrong last position"); $lastPosition = uPosition::getLast($this->testUserId2); - $this->assertEquals($lastPosition->id, $pos4, "Wrong last position (user)"); + self::assertEquals($lastPosition->id, $pos4, "Wrong last position (user)"); } - public function testGetLastAllUsers() { + public function testGetLastAllUsers(): void { $userId = $this->addTestUser(); $userId2 = $this->addTestUser($this->testUser2); $trackId1 = $this->addTestTrack($userId); @@ -114,30 +114,30 @@ class PositionTest extends UloggerDatabaseTestCase { $pos2 = $this->addTestPosition($userId2, $trackId2, $this->testTimestamp + 1); $pos3 = $this->addTestPosition($userId, $trackId1, $this->testTimestamp); $pos4 = $this->addTestPosition($userId2, $trackId2, $this->testTimestamp + 2); - $this->assertEquals(2, $this->getConnection()->getRowCount('tracks'), "Wrong row count"); - $this->assertEquals(4, $this->getConnection()->getRowCount('positions'), "Wrong row count"); + self::assertEquals(2, $this->getConnection()->getRowCount('tracks'), "Wrong row count"); + self::assertEquals(4, $this->getConnection()->getRowCount('positions'), "Wrong row count"); $posArr = uPosition::getLastAllUsers(); - $this->assertCount(2, $posArr, "Wrong row count"); + self::assertCount(2, $posArr, "Wrong row count"); foreach ($posArr as $position) { /** @var uPosition $position */ switch ($position->id) { case 1: - $this->assertEquals($this->testTimestamp + 3, $position->timestamp); - $this->assertEquals($userId, $position->userId); - $this->assertEquals($trackId1, $position->trackId); + self::assertEquals($this->testTimestamp + 3, $position->timestamp); + self::assertEquals($userId, $position->userId); + self::assertEquals($trackId1, $position->trackId); break; case 4: - $this->assertEquals($this->testTimestamp + 2, $position->timestamp); - $this->assertEquals($userId2, $position->userId); - $this->assertEquals($trackId2, $position->trackId); + self::assertEquals($this->testTimestamp + 2, $position->timestamp); + self::assertEquals($userId2, $position->userId); + self::assertEquals($trackId2, $position->trackId); break; default: - $this->assertTrue(false, "Unexpected position: {$position->id}"); + self::assertTrue(false, "Unexpected position: $position->id"); } } } - public function testGetAll() { + public function testGetAll(): void { $userId = $this->addTestUser(); $userId2 = $this->addTestUser($this->testUser2); $userId3 = $this->addTestUser("testUser3"); @@ -147,39 +147,39 @@ class PositionTest extends UloggerDatabaseTestCase { $this->addTestPosition($userId, $trackId2); $trackId3 = $this->addTestTrack($userId2); $this->addTestPosition($userId2, $trackId3); - $this->assertEquals(3, $this->getConnection()->getRowCount('tracks'), "Wrong row count"); - $this->assertEquals(3, $this->getConnection()->getRowCount('positions'), "Wrong row count"); + self::assertEquals(3, $this->getConnection()->getRowCount('tracks'), "Wrong row count"); + self::assertEquals(3, $this->getConnection()->getRowCount('positions'), "Wrong row count"); $posArr = uPosition::getAll(); - $this->assertCount(3, $posArr, "Wrong row count"); + self::assertCount(3, $posArr, "Wrong row count"); $posArr = uPosition::getAll($userId); - $this->assertCount(2, $posArr, "Wrong row count"); + self::assertCount(2, $posArr, "Wrong row count"); $posArr = uPosition::getAll($userId, $trackId); - $this->assertCount(1, $posArr, "Wrong row count"); + self::assertCount(1, $posArr, "Wrong row count"); $posArr = uPosition::getAll(NULL, $trackId); - $this->assertCount(1, $posArr, "Wrong row count"); + self::assertCount(1, $posArr, "Wrong row count"); $posArr = uPosition::getAll($userId3); - $this->assertCount(0, $posArr, "Wrong row count"); + self::assertCount(0, $posArr, "Wrong row count"); } - public function testDistanceTo() { + public function testDistanceTo(): void { $userId = $this->addTestUser(); $trackId = $this->addTestTrack($userId); $pos1 = $this->addTestPosition($userId, $trackId, $this->testTimestamp, 0, 0); $pos2 = $this->addTestPosition($userId, $trackId, $this->testTimestamp, 0, 1); $posArr = uPosition::getAll(); - $this->assertCount(2, $posArr, "Wrong row count"); - $this->assertEquals(111195, round($posArr[0]->distanceTo($posArr[1])), "Wrong distance"); + self::assertCount(2, $posArr, "Wrong row count"); + self::assertEquals(111195, round($posArr[0]->distanceTo($posArr[1])), "Wrong distance"); } - public function testSecondsTo() { + public function testSecondsTo(): void { $userId = $this->addTestUser(); $trackId = $this->addTestTrack($userId); $pos1 = $this->addTestPosition($userId, $trackId, $this->testTimestamp); $pos2 = $this->addTestPosition($userId, $trackId, $this->testTimestamp + 1); $posArr = uPosition::getAll(); - $this->assertCount(2, $posArr, "Wrong row count"); - $this->assertEquals(-1, $posArr[0]->secondsTo($posArr[1]), "Wrong time difference"); + self::assertCount(2, $posArr, "Wrong row count"); + self::assertEquals(-1, $posArr[0]->secondsTo($posArr[1]), "Wrong time difference"); } } diff --git a/.tests/tests/SetupTest.php b/.tests/tests/SetupTest.php index 8c7dc0e..6766df1 100644 --- a/.tests/tests/SetupTest.php +++ b/.tests/tests/SetupTest.php @@ -1,29 +1,40 @@ http->get($this->script); - $this->assertEquals(200, $response->getStatusCode(), "Unexpected status code"); + self::assertEquals(200, $response->getStatusCode(), "Unexpected status code"); $body = (string) $response->getBody(); - $this->assertContains("", $body); + self::assertStringContainsString("", $body); } - public function testSetupPhase() { + /** + * @throws GuzzleException + */ + public function testSetupPhase(): void { $options = [ "http_errors" => false, "form_params" => [ "command" => "setup" ] ]; $response = $this->http->post($this->script, $options); - $this->assertEquals(200, $response->getStatusCode(), "Unexpected status code"); + self::assertEquals(200, $response->getStatusCode(), "Unexpected status code"); $body = (string) $response->getBody(); - $this->assertContains("", $body); + self::assertStringContainsString("", $body); } - public function testAdduserPhase() { + /** + * @throws GuzzleException + */ + public function testAdduserPhase(): void { $options = [ "http_errors" => false, "form_params" => [ @@ -34,14 +45,14 @@ class SetupTest extends UloggerAPITestCase { ] ]; $response = $this->http->post($this->script, $options); - $this->assertEquals(200, $response->getStatusCode(), "Unexpected status code"); + self::assertEquals(200, $response->getStatusCode(), "Unexpected status code"); $body = (string) $response->getBody(); - $this->assertContains("", $body); - $this->assertEquals(2, $this->getConnection()->getRowCount("users"), "Wrong row count"); + self::assertStringContainsString("", $body); + self::assertEquals(2, $this->getConnection()->getRowCount("users"), "Wrong row count"); $expected = [ "id" => 2, "login" => $this->testUser, "admin" => 1 ]; $actual = $this->getConnection()->createQueryTable("users", "SELECT id, login, admin FROM users WHERE id = 2"); $this->assertTableContains($expected, $actual, "Wrong actual table data"); - $this->assertTrue(password_verify($this->testPass, $this->pdoGetColumn("SELECT password FROM users WHERE id = 2")), "Wrong actual password hash"); + self::assertTrue(password_verify($this->testPass, $this->pdoGetColumn("SELECT password FROM users WHERE id = 2")), "Wrong actual password hash"); } } diff --git a/.tests/tests/TrackTest.php b/.tests/tests/TrackTest.php index 30e8bb6..7dce897 100644 --- a/.tests/tests/TrackTest.php +++ b/.tests/tests/TrackTest.php @@ -1,57 +1,56 @@ addTestUser(); $trackId = uTrack::add($this->testUserId, $this->testTrackName, $this->testTrackComment); - $this->assertNotFalse($trackId, "Track id should not be false"); - $this->assertEquals(1, $this->getConnection()->getRowCount('tracks'), "Wrong row count"); - $this->assertEquals(1, $trackId, "Wrong track id returned"); + self::assertNotFalse($trackId, "Track id should not be false"); + self::assertEquals(1, $this->getConnection()->getRowCount('tracks'), "Wrong row count"); + self::assertEquals(1, $trackId, "Wrong track id returned"); $expected = [ "id" => $trackId, "user_id" => $this->testUserId, "name" => $this->testTrackName, "comment" => $this->testTrackComment ]; $actual = $this->getConnection()->createQueryTable("tracks", "SELECT id, user_id, name, comment FROM tracks"); $this->assertTableContains($expected, $actual, "Wrong actual table data"); - $this->assertFalse(uTrack::add("", $this->testTrackName), "Adding track with empty user id should fail"); - $this->assertFalse(uTrack::add($this->testUserId, ""), "Adding track with empty name should fail"); + self::assertFalse(uTrack::add("", $this->testTrackName), "Adding track with empty user id should fail"); + self::assertFalse(uTrack::add($this->testUserId, ""), "Adding track with empty name should fail"); } - public function testDeleteTrack() { + public function testDeleteTrack(): void { $userId = $this->addTestUser(); $trackId = $this->addTestTrack($userId); $this->addTestPosition($userId, $trackId); - $this->assertEquals(1, $this->getConnection()->getRowCount('tracks'), "Wrong row count"); - $this->assertEquals(1, $this->getConnection()->getRowCount('positions'), "Wrong row count"); + self::assertEquals(1, $this->getConnection()->getRowCount('tracks'), "Wrong row count"); + self::assertEquals(1, $this->getConnection()->getRowCount('positions'), "Wrong row count"); $track = new uTrack($trackId); $track->delete(); - $this->assertEquals(0, $this->getConnection()->getRowCount('tracks'), "Wrong row count"); - $this->assertEquals(0, $this->getConnection()->getRowCount('positions'), "Wrong row count"); - $this->assertFalse($track->isValid, "Deleted track should not be valid"); + self::assertEquals(0, $this->getConnection()->getRowCount('tracks'), "Wrong row count"); + self::assertEquals(0, $this->getConnection()->getRowCount('positions'), "Wrong row count"); + self::assertFalse($track->isValid, "Deleted track should not be valid"); } - public function testAddPosition() { + public function testAddPosition(): void { $userId = $this->addTestUser(); $userId2 = $this->addTestUser($this->testUser2); $trackId = $this->addTestTrack($userId); - $this->assertEquals(1, $this->getConnection()->getRowCount('tracks'), "Wrong row count"); + self::assertEquals(1, $this->getConnection()->getRowCount('tracks'), "Wrong row count"); $track = new uTrack($trackId + 1); $posId = $track->addPosition($userId, $this->testTimestamp, $this->testLat, $this->testLon, $this->testAltitude, $this->testSpeed, $this->testBearing, $this->testAccuracy, $this->testProvider, $this->testComment, $this->testImage); - $this->assertEquals(0, $this->getConnection()->getRowCount('positions'), "Wrong row count"); - $this->assertFalse($posId, "Adding position with nonexistant track should fail"); + self::assertEquals(0, $this->getConnection()->getRowCount('positions'), "Wrong row count"); + self::assertFalse($posId, "Adding position with nonexistant track should fail"); $track = new uTrack($trackId); $posId = $track->addPosition($userId2, $this->testTimestamp, $this->testLat, $this->testLon, $this->testAltitude, $this->testSpeed, $this->testBearing, $this->testAccuracy, $this->testProvider, $this->testComment, $this->testImage); - $this->assertEquals(0, $this->getConnection()->getRowCount('positions'), "Wrong row count"); - $this->assertFalse($posId, "Adding position with wrong user should fail"); + self::assertEquals(0, $this->getConnection()->getRowCount('positions'), "Wrong row count"); + self::assertFalse($posId, "Adding position with wrong user should fail"); $posId = $track->addPosition($userId, $this->testTimestamp, $this->testLat, $this->testLon, $this->testAltitude, $this->testSpeed, $this->testBearing, $this->testAccuracy, $this->testProvider, $this->testComment, $this->testImage); - $this->assertEquals(1, $this->getConnection()->getRowCount('positions'), "Wrong row count"); + self::assertEquals(1, $this->getConnection()->getRowCount('positions'), "Wrong row count"); $expected = [ "id" => $posId, "user_id" => $this->testUserId, @@ -74,31 +73,31 @@ class TrackTest extends UloggerDatabaseTestCase { $this->assertTableContains($expected, $actual, "Wrong actual table data"); $posId = $track->addPosition($userId, NULL, $this->testLat, $this->testLon); - $this->assertFalse($posId, "Adding position with null time stamp should fail"); + self::assertFalse($posId, "Adding position with null time stamp should fail"); $posId = $track->addPosition($userId, $this->testTimestamp, NULL, $this->testLon); - $this->assertFalse($posId, "Adding position with null latitude should fail"); + self::assertFalse($posId, "Adding position with null latitude should fail"); $posId = $track->addPosition($userId, $this->testTimestamp, $this->testLat, NULL); - $this->assertFalse($posId, "Adding position with null longitude should fail"); + self::assertFalse($posId, "Adding position with null longitude should fail"); $posId = $track->addPosition($userId, "", $this->testLat, $this->testLon); - $this->assertFalse($posId, "Adding position with empty time stamp should fail"); + self::assertFalse($posId, "Adding position with empty time stamp should fail"); $posId = $track->addPosition($userId, $this->testTimestamp, "", $this->testLon); - $this->assertFalse($posId, "Adding position with empty latitude should fail"); + self::assertFalse($posId, "Adding position with empty latitude should fail"); $posId = $track->addPosition($userId, $this->testTimestamp, $this->testLat, ""); - $this->assertFalse($posId, "Adding position with empty longitude should fail"); + self::assertFalse($posId, "Adding position with empty longitude should fail"); } - public function testGetAll() { + public function testGetAll(): void { $this->addTestTrack($this->addTestUser()); $this->addTestTrack($this->addTestUser($this->testUser2)); - $this->assertEquals(2, $this->getConnection()->getRowCount('tracks'), "Wrong row count"); + self::assertEquals(2, $this->getConnection()->getRowCount('tracks'), "Wrong row count"); $trackArr = uTrack::getAll(); - $this->assertEquals(2, count($trackArr), "Wrong array size"); - $this->assertTrue($trackArr[0] instanceof uTrack, "Wrong array member"); + self::assertCount(2, $trackArr, "Wrong array size"); + self::assertInstanceOf(uTrack::class, $trackArr[0], "Wrong array member"); } - public function testDeleteAll() { + public function testDeleteAll(): void { $userId = $this->addTestUser(); $trackId = $this->addTestTrack($userId); $this->addTestTrack($userId); @@ -108,16 +107,16 @@ class TrackTest extends UloggerDatabaseTestCase { $trackId2 = $this->addTestTrack($userId2); $this->addTestPosition($userId2, $trackId2); - $this->assertEquals(3, $this->getConnection()->getRowCount('tracks'), "Wrong row count"); - $this->assertEquals(2, $this->getConnection()->getRowCount('positions'), "Wrong row count"); + self::assertEquals(3, $this->getConnection()->getRowCount('tracks'), "Wrong row count"); + self::assertEquals(2, $this->getConnection()->getRowCount('positions'), "Wrong row count"); uTrack::deleteAll($userId); - $this->assertEquals(1, $this->getConnection()->getRowCount('tracks'), "Wrong row count"); - $this->assertEquals(1, $this->getConnection()->getRowCount('positions'), "Wrong row count"); - $this->assertFalse(uTrack::deleteAll(NULL), "User id should not be empty"); + self::assertEquals(1, $this->getConnection()->getRowCount('tracks'), "Wrong row count"); + self::assertEquals(1, $this->getConnection()->getRowCount('positions'), "Wrong row count"); + self::assertFalse(uTrack::deleteAll(NULL), "User id should not be empty"); } - public function testUpdate() { + public function testUpdate(): void { $userId = $this->addTestUser(); $trackId = $this->addTestTrack($userId); $track = new uTrack($trackId); @@ -127,16 +126,16 @@ class TrackTest extends UloggerDatabaseTestCase { $this->assertTableContains($expected, $actual, "Wrong actual table data"); $trackInvalid = new uTrack($trackId + 1); - $this->assertFalse($trackInvalid->update("newName", "newComment"), "Updating nonexistant track should fail"); + self::assertFalse($trackInvalid->update("newName", "newComment"), "Updating nonexistant track should fail"); } - public function testIsValid() { + public function testIsValid(): void { $userId = $this->addTestUser(); $trackId = $this->addTestTrack($userId); $trackValid = new uTrack($trackId); - $this->assertTrue($trackValid->isValid, "Track should be valid"); + self::assertTrue($trackValid->isValid, "Track should be valid"); $trackInvalid = new uTrack($trackId + 1); - $this->assertFalse($trackInvalid->isValid, "Track should not be valid"); + self::assertFalse($trackInvalid->isValid, "Track should not be valid"); } } ?> diff --git a/.tests/tests/UserTest.php b/.tests/tests/UserTest.php index 2df6435..4bad7cd 100644 --- a/.tests/tests/UserTest.php +++ b/.tests/tests/UserTest.php @@ -5,93 +5,93 @@ require_once(__DIR__ . "/../../helpers/user.php"); class UserTest extends UloggerDatabaseTestCase { - public function testAddUser() { + public function testAddUser(): void { $userId = uUser::add($this->testUser, $this->testPass); - $this->assertEquals(1, $this->getConnection()->getRowCount('users'), "Wrong row count"); - $this->assertEquals(1, $userId, "Wrong user id returned"); + self::assertEquals(1, $this->getConnection()->getRowCount('users'), "Wrong row count"); + self::assertEquals(1, $userId, "Wrong user id returned"); $expected = [ "id" => 1, "login" => $this->testUser ]; $actual = $this->getConnection()->createQueryTable("users", "SELECT id, login FROM users"); $this->assertTableContains($expected, $actual, "Wrong actual table data"); - $this->assertTrue(password_verify($this->testPass, $this->pdoGetColumn("SELECT password FROM users")), "Wrong actual password hash"); - $this->assertFalse(uUser::add($this->testUser, $this->testPass), "Adding user with same login should fail"); - $this->assertFalse(uUser::add($this->testUser, ""), "Adding user with empty password should fail"); - $this->assertFalse(uUser::add("", $this->testPass), "Adding user with empty login should fail"); + self::assertTrue(password_verify($this->testPass, $this->pdoGetColumn("SELECT password FROM users")), "Wrong actual password hash"); + self::assertFalse(uUser::add($this->testUser, $this->testPass), "Adding user with same login should fail"); + self::assertFalse(uUser::add($this->testUser, ""), "Adding user with empty password should fail"); + self::assertFalse(uUser::add("", $this->testPass), "Adding user with empty login should fail"); } - public function testDeleteUser() { + public function testDeleteUser(): void { $userId = $this->addTestUser($this->testUser); $trackId = $this->addTestTrack($userId); $this->addTestPosition($userId, $trackId); - $this->assertEquals(1, $this->getConnection()->getRowCount('users'), "Wrong row count"); - $this->assertEquals(1, $this->getConnection()->getRowCount('tracks'), "Wrong row count"); - $this->assertEquals(1, $this->getConnection()->getRowCount('positions'), "Wrong row count"); + self::assertEquals(1, $this->getConnection()->getRowCount('users'), "Wrong row count"); + self::assertEquals(1, $this->getConnection()->getRowCount('tracks'), "Wrong row count"); + self::assertEquals(1, $this->getConnection()->getRowCount('positions'), "Wrong row count"); $user = new uUser($this->testUser); $user->delete(); - $this->assertEquals(0, $this->getConnection()->getRowCount('users'), "Wrong row count"); - $this->assertEquals(0, $this->getConnection()->getRowCount('tracks'), "Wrong row count"); - $this->assertEquals(0, $this->getConnection()->getRowCount('positions'), "Wrong row count"); - $this->assertFalse($user->isValid, "Deleted user should not be valid"); + self::assertEquals(0, $this->getConnection()->getRowCount('users'), "Wrong row count"); + self::assertEquals(0, $this->getConnection()->getRowCount('tracks'), "Wrong row count"); + self::assertEquals(0, $this->getConnection()->getRowCount('positions'), "Wrong row count"); + self::assertFalse($user->isValid, "Deleted user should not be valid"); } - public function testSetPass() { + public function testSetPass(): void { $newPass = $this->testPass . "new"; $this->addTestUser($this->testUser); - $this->assertEquals(1, $this->getConnection()->getRowCount('users'), "Wrong row count"); + self::assertEquals(1, $this->getConnection()->getRowCount('users'), "Wrong row count"); $user = new uUser($this->testUser); $user->setPass($newPass); - $this->assertTrue(password_verify($newPass, $this->pdoGetColumn("SELECT password FROM users")), "Wrong actual password hash"); - $this->assertFalse($user->setPass(""), "Password should not be empty"); + self::assertTrue(password_verify($newPass, $this->pdoGetColumn("SELECT password FROM users")), "Wrong actual password hash"); + self::assertFalse($user->setPass(""), "Password should not be empty"); $userInvalid = new uUser($this->testUser . "-noexistant"); - $this->assertFalse($userInvalid->setPass($newPass), "Setting pass for nonexistant user should fail"); + self::assertFalse($userInvalid->setPass($newPass), "Setting pass for nonexistant user should fail"); } - public function testSetAdmin() { + public function testSetAdmin(): void { $this->addTestUser($this->testUser); - $this->assertEquals(1, $this->getConnection()->getRowCount('users'), "Wrong row count"); + self::assertEquals(1, $this->getConnection()->getRowCount('users'), "Wrong row count"); $user = new uUser($this->testUser); - $this->assertFalse((bool) $this->pdoGetColumn("SELECT admin FROM users"), "User should not be admin"); - $this->assertFalse($user->isAdmin, "User should not be admin"); + self::assertFalse((bool) $this->pdoGetColumn("SELECT admin FROM users"), "User should not be admin"); + self::assertFalse($user->isAdmin, "User should not be admin"); $user->setAdmin(true); - $this->assertTrue((bool) $this->pdoGetColumn("SELECT admin FROM users"), "User should be admin"); - $this->assertTrue($user->isAdmin, "User should be admin"); + self::assertTrue((bool) $this->pdoGetColumn("SELECT admin FROM users"), "User should be admin"); + self::assertTrue($user->isAdmin, "User should be admin"); $user->setAdmin(false); - $this->assertFalse((bool) $this->pdoGetColumn("SELECT admin FROM users"), "User should not be admin"); - $this->assertFalse($user->isAdmin, "User should not be admin"); + self::assertFalse((bool) $this->pdoGetColumn("SELECT admin FROM users"), "User should not be admin"); + self::assertFalse($user->isAdmin, "User should not be admin"); } - public function testGetAll() { + public function testGetAll(): void { $this->addTestUser($this->testUser); $this->addTestUser($this->testUser2); - $this->assertEquals(2, $this->getConnection()->getRowCount('users'), "Wrong row count"); + self::assertEquals(2, $this->getConnection()->getRowCount('users'), "Wrong row count"); $userArr = uUser::getAll(); - $this->assertCount(2, $userArr, "Wrong array size"); - $this->assertInstanceOf(uUser::class, $userArr[0], "Wrong array member"); + self::assertCount(2, $userArr, "Wrong array size"); + self::assertInstanceOf(uUser::class, $userArr[0], "Wrong array member"); } - public function testIsAdmin() { + public function testIsAdmin(): void { $this->addTestUser($this->testUser, NULL, true); $user = new uUser($this->testUser); - $this->assertTrue($user->isAdmin, "User should be admin"); + self::assertTrue($user->isAdmin, "User should be admin"); } - public function testIsNotAdmin() { + public function testIsNotAdmin(): void { $this->addTestUser($this->testUser); $user = new uUser($this->testUser); - $this->assertFalse($user->isAdmin, "User should not be admin"); + self::assertFalse($user->isAdmin, "User should not be admin"); } - public function testIsValid() { + public function testIsValid(): void { $this->addTestUser($this->testUser); $userValid = new uUser($this->testUser); - $this->assertTrue($userValid->isValid, "User should be valid"); + self::assertTrue($userValid->isValid, "User should be valid"); $userInvalid = new uUser($this->testUser . "-noexistant"); - $this->assertFalse($userInvalid->isValid, "User should not be valid"); + self::assertFalse($userInvalid->isValid, "User should not be valid"); } } ?> diff --git a/.tests/tests/UtilsTest.php b/.tests/tests/UtilsTest.php index a6dd79a..0c8e40c 100644 --- a/.tests/tests/UtilsTest.php +++ b/.tests/tests/UtilsTest.php @@ -1,33 +1,38 @@ setAccessible(true); ini_set("memory_limit", "1G"); $result = $iniGetBytes->invoke(null, "memory_limit"); - $this->assertEquals(1024 * 1024 * 1024, $result); + self::assertEquals(1024 * 1024 * 1024, $result); ini_set("memory_limit", 100 . "M"); $result = $iniGetBytes->invoke(null, "memory_limit"); - $this->assertEquals(100 * 1024 * 1024, $result); + self::assertEquals(100 * 1024 * 1024, $result); ini_set("memory_limit", 100 * 1024 . "K"); $result = $iniGetBytes->invoke(null, "memory_limit"); - $this->assertEquals(100 * 1024 * 1024, $result); + self::assertEquals(100 * 1024 * 1024, $result); ini_set("memory_limit", 100 * 1024 * 1024); $result = $iniGetBytes->invoke(null, "memory_limit"); - $this->assertEquals(100 * 1024 * 1024, $result); + self::assertEquals(100 * 1024 * 1024, $result); } - public function testGetBaseUrlMain() { + /** @noinspection HttpUrlsUsage */ + public function testGetBaseUrlMain(): void { if (!defined("ROOT_DIR")) { define("ROOT_DIR", "/var/www/html/ulogger"); } @@ -38,10 +43,11 @@ class UtilsTest extends TestCase { $_SERVER["PHP_SELF"] = "/index.php"; $result = uUtils::getBaseUrl(); $expected = "http://www.example.com/"; - $this->assertEquals($expected, $result); + self::assertEquals($expected, $result); } - public function testGetBaseUrlScript() { + /** @noinspection HttpUrlsUsage */ + public function testGetBaseUrlScript(): void { if (!defined("ROOT_DIR")) { define("ROOT_DIR", "/var/www/html"); } @@ -52,10 +58,11 @@ class UtilsTest extends TestCase { $_SERVER["PHP_SELF"] = "/utils/test.php"; $result = uUtils::getBaseUrl(); $expected = "http://www.example.com/"; - $this->assertEquals($expected, $result); + self::assertEquals($expected, $result); } - public function testGetBaseUrlSubfolder() { + /** @noinspection HttpUrlsUsage */ + public function testGetBaseUrlSubfolder(): void { if (!defined("ROOT_DIR")) { define("ROOT_DIR", "/var/www/html"); } @@ -66,10 +73,10 @@ class UtilsTest extends TestCase { $_SERVER["PHP_SELF"] = "/ulogger/index.php"; $result = uUtils::getBaseUrl(); $expected = "http://www.example.com/ulogger/"; - $this->assertEquals($expected, $result); + self::assertEquals($expected, $result); } - public function testGetBaseUrlHttps() { + public function testGetBaseUrlHttps(): void { if (!defined("ROOT_DIR")) { define("ROOT_DIR", "/var/www/html"); } @@ -80,10 +87,11 @@ class UtilsTest extends TestCase { $_SERVER["PHP_SELF"] = "/index.php"; $result = uUtils::getBaseUrl(); $expected = "https://www.example.com/"; - $this->assertEquals($expected, $result); + self::assertEquals($expected, $result); } - public function testGetBaseUrlHttp() { + /** @noinspection HttpUrlsUsage */ + public function testGetBaseUrlHttp(): void { if (!defined("ROOT_DIR")) { define("ROOT_DIR", "/var/www/html"); } @@ -94,26 +102,26 @@ class UtilsTest extends TestCase { $_SERVER["PHP_SELF"] = "/index.php"; $result = uUtils::getBaseUrl(); $expected = "http://www.example.com/"; - $this->assertEquals($expected, $result); + self::assertEquals($expected, $result); unset($_SERVER["HTTPS"]); - $this->assertEquals($expected, $result); + self::assertEquals($expected, $result); } - public function testIsAbsolutePath() { - $this->assertTrue(uUtils::isAbsolutePath("/foo")); - $this->assertTrue(uUtils::isAbsolutePath("/foo/bar")); - $this->assertTrue(uUtils::isAbsolutePath("/")); - $this->assertTrue(uUtils::isAbsolutePath("/.")); - $this->assertTrue(uUtils::isAbsolutePath("\\")); - $this->assertTrue(uUtils::isAbsolutePath("C:\\\\foo")); - $this->assertTrue(uUtils::isAbsolutePath("Z:\\\\FOO/BAR")); + public function testIsAbsolutePath(): void { + self::assertTrue(uUtils::isAbsolutePath("/foo")); + self::assertTrue(uUtils::isAbsolutePath("/foo/bar")); + self::assertTrue(uUtils::isAbsolutePath("/")); + self::assertTrue(uUtils::isAbsolutePath("/.")); + self::assertTrue(uUtils::isAbsolutePath("\\")); + self::assertTrue(uUtils::isAbsolutePath("C:\\\\foo")); + self::assertTrue(uUtils::isAbsolutePath("Z:\\\\FOO/BAR")); - $this->assertFalse(uUtils::isAbsolutePath("foo")); - $this->assertFalse(uUtils::isAbsolutePath("foo/bar")); - $this->assertFalse(uUtils::isAbsolutePath("./foo")); - $this->assertFalse(uUtils::isAbsolutePath("../")); - $this->assertFalse(uUtils::isAbsolutePath(".\\foo")); + self::assertFalse(uUtils::isAbsolutePath("foo")); + self::assertFalse(uUtils::isAbsolutePath("foo/bar")); + self::assertFalse(uUtils::isAbsolutePath("./foo")); + self::assertFalse(uUtils::isAbsolutePath("../")); + self::assertFalse(uUtils::isAbsolutePath(".\\foo")); } } ?> diff --git a/.travis.yml b/.travis.yml index a4750cc..143e411 100644 --- a/.travis.yml +++ b/.travis.yml @@ -3,7 +3,7 @@ os: linux dist: xenial php: - - 7.2 + - 7.4 env: jobs: @@ -63,7 +63,7 @@ after_failure: - docker logs ulogger script: - - ./vendor/bin/phpunit -c .tests/phpunit.xml + - XDEBUG_MODE=coverage ./vendor/bin/phpunit -c .tests/phpunit.xml - npm test - npm run lint:js - npm run lint:css diff --git a/README.md b/README.md index d4358e6..258b37e 100644 --- a/README.md +++ b/README.md @@ -66,9 +66,10 @@ Together with a dedicated [μlogger mobile client](https://github.com/bfabiszews - For example: `docker run --name ulogger -e ULOGGER_LANG="pl" -p 8080:80 -d bfabiszewski/ulogger` - You may also build the image yourself. Run `docker build .` from the root folder where `Dockerfile` reside. There are optional build-time arguments that allow you to set default database passwords for root and ulogger users - For example: `docker build --build-arg DB_ROOT_PASS=secret1 --build-arg DB_USER_PASS=secret2 --build-arg DB_DRIVER=sqlite .` +- Docker was created to facilitate development and testing. It is not production ready. If you want to use it in production, you will have to adjust it to your needs. ## Tests -- Install tests dependecies. +- Install tests dependecies. PHP tests require PHP >= 7.3. - `composer install` - `npm install` - Integration tests may be run against docker image. We need exposed http and optionally database ports (eg. mapped to localhost 8080 and 8081). Below example for MySQL setup @@ -80,7 +81,7 @@ Together with a dedicated [μlogger mobile client](https://github.com/bfabiszews - `DB_PASS=secret2` - `ULOGGER_URL="http://127.0.0.1:8080"` - PHP tests - - `./vendor/bin/phpunit -c .tests/phpunit.xml` + - `XDEBUG_MODE=coverage ./vendor/bin/phpunit -c .tests/phpunit.xml` - JS tests - `npm test` - Other tests diff --git a/composer.json b/composer.json index 292e2b0..0417144 100644 --- a/composer.json +++ b/composer.json @@ -1,4 +1,6 @@ { + "name": "bfabiszewski/ulogger-server", + "description": "ulogger server", "require": { "ulrichsg/getopt-php": "^3.2", "ext-json": "*", @@ -8,12 +10,13 @@ "ext-libxml": "*" }, "scripts": { - "test": "./vendor/bin/phpunit" + "test": [ "@putenv XDEBUG_MODE=coverage", "./vendor/bin/phpunit" ] }, "require-dev": { - "phpunit/phpunit": "^5.7", - "vlucas/phpdotenv": "^3.3", - "guzzlehttp/guzzle": "^6.3", - "phpunit/dbunit": "^2.0" + "roave/security-advisories": "dev-latest", + "phpunit/phpunit": "^9.5", + "vlucas/phpdotenv": "^5.3", + "guzzlehttp/guzzle": "^7.3", + "kornrunner/dbunit": "^6.0" } } diff --git a/composer.lock b/composer.lock index 3258483..55f3266 100644 --- a/composer.lock +++ b/composer.lock @@ -1,23 +1,23 @@ { "_readme": [ "This file locks the dependencies of your project to a known state", - "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#composer-lock-the-lock-file", + "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies", "This file is @generated automatically" ], - "content-hash": "ffb1c6d77d755002ea20d1c1c6338b43", + "content-hash": "1a3c4445dd142c9b904638bfe4a58a63", "packages": [ { "name": "ulrichsg/getopt-php", - "version": "3.2.2", + "version": "v3.4.0", "source": { "type": "git", "url": "https://github.com/getopt-php/getopt-php.git", - "reference": "9df490db25bd192d074f5de4210e232a8ddbeda0" + "reference": "9121d7c2c51a6a59ee407c49a13b4d8cfae71075" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/getopt-php/getopt-php/zipball/9df490db25bd192d074f5de4210e232a8ddbeda0", - "reference": "9df490db25bd192d074f5de4210e232a8ddbeda0", + "url": "https://api.github.com/repos/getopt-php/getopt-php/zipball/9121d7c2c51a6a59ee407c49a13b4d8cfae71075", + "reference": "9121d7c2c51a6a59ee407c49a13b4d8cfae71075", "shasum": "" }, "require": { @@ -48,42 +48,43 @@ "email": "thflori@gmail.com" } ], - "description": "Command line arguments parser for PHP 5.4 - 7.1", + "description": "Command line arguments parser for PHP 5.4 - 7.3", "homepage": "http://getopt-php.github.io/getopt-php", - "time": "2019-01-22T08:01:50+00:00" + "support": { + "issues": "https://github.com/getopt-php/getopt-php/issues", + "source": "https://github.com/getopt-php/getopt-php/tree/v3.4.0" + }, + "time": "2020-07-14T06:09:04+00:00" } ], "packages-dev": [ { "name": "doctrine/instantiator", - "version": "1.1.0", + "version": "1.4.0", "source": { "type": "git", "url": "https://github.com/doctrine/instantiator.git", - "reference": "185b8868aa9bf7159f5f953ed5afb2d7fcdc3bda" + "reference": "d56bf6102915de5702778fe20f2de3b2fe570b5b" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/doctrine/instantiator/zipball/185b8868aa9bf7159f5f953ed5afb2d7fcdc3bda", - "reference": "185b8868aa9bf7159f5f953ed5afb2d7fcdc3bda", + "url": "https://api.github.com/repos/doctrine/instantiator/zipball/d56bf6102915de5702778fe20f2de3b2fe570b5b", + "reference": "d56bf6102915de5702778fe20f2de3b2fe570b5b", "shasum": "" }, "require": { - "php": "^7.1" + "php": "^7.1 || ^8.0" }, "require-dev": { - "athletic/athletic": "~0.1.8", + "doctrine/coding-standard": "^8.0", "ext-pdo": "*", "ext-phar": "*", - "phpunit/phpunit": "^6.2.3", - "squizlabs/php_codesniffer": "^3.0.2" + "phpbench/phpbench": "^0.13 || 1.0.0-alpha2", + "phpstan/phpstan": "^0.12", + "phpstan/phpstan-phpunit": "^0.12", + "phpunit/phpunit": "^7.0 || ^8.0 || ^9.0" }, "type": "library", - "extra": { - "branch-alias": { - "dev-master": "1.2.x-dev" - } - }, "autoload": { "psr-4": { "Doctrine\\Instantiator\\": "src/Doctrine/Instantiator/" @@ -97,57 +98,150 @@ { "name": "Marco Pivetta", "email": "ocramius@gmail.com", - "homepage": "http://ocramius.github.com/" + "homepage": "https://ocramius.github.io/" } ], "description": "A small, lightweight utility to instantiate objects in PHP without invoking their constructors", - "homepage": "https://github.com/doctrine/instantiator", + "homepage": "https://www.doctrine-project.org/projects/instantiator.html", "keywords": [ "constructor", "instantiate" ], - "time": "2017-07-22T11:58:36+00:00" + "support": { + "issues": "https://github.com/doctrine/instantiator/issues", + "source": "https://github.com/doctrine/instantiator/tree/1.4.0" + }, + "funding": [ + { + "url": "https://www.doctrine-project.org/sponsorship.html", + "type": "custom" + }, + { + "url": "https://www.patreon.com/phpdoctrine", + "type": "patreon" + }, + { + "url": "https://tidelift.com/funding/github/packagist/doctrine%2Finstantiator", + "type": "tidelift" + } + ], + "time": "2020-11-10T18:47:58+00:00" }, { - "name": "guzzlehttp/guzzle", - "version": "6.3.3", + "name": "graham-campbell/result-type", + "version": "v1.0.1", "source": { "type": "git", - "url": "https://github.com/guzzle/guzzle.git", - "reference": "407b0cb880ace85c9b63c5f9551db498cb2d50ba" + "url": "https://github.com/GrahamCampbell/Result-Type.git", + "reference": "7e279d2cd5d7fbb156ce46daada972355cea27bb" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/guzzle/guzzle/zipball/407b0cb880ace85c9b63c5f9551db498cb2d50ba", - "reference": "407b0cb880ace85c9b63c5f9551db498cb2d50ba", + "url": "https://api.github.com/repos/GrahamCampbell/Result-Type/zipball/7e279d2cd5d7fbb156ce46daada972355cea27bb", + "reference": "7e279d2cd5d7fbb156ce46daada972355cea27bb", "shasum": "" }, "require": { - "guzzlehttp/promises": "^1.0", - "guzzlehttp/psr7": "^1.4", - "php": ">=5.5" + "php": "^7.0|^8.0", + "phpoption/phpoption": "^1.7.3" }, "require-dev": { + "phpunit/phpunit": "^6.5|^7.5|^8.5|^9.0" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "1.0-dev" + } + }, + "autoload": { + "psr-4": { + "GrahamCampbell\\ResultType\\": "src/" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Graham Campbell", + "email": "graham@alt-three.com" + } + ], + "description": "An Implementation Of The Result Type", + "keywords": [ + "Graham Campbell", + "GrahamCampbell", + "Result Type", + "Result-Type", + "result" + ], + "support": { + "issues": "https://github.com/GrahamCampbell/Result-Type/issues", + "source": "https://github.com/GrahamCampbell/Result-Type/tree/v1.0.1" + }, + "funding": [ + { + "url": "https://github.com/GrahamCampbell", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/graham-campbell/result-type", + "type": "tidelift" + } + ], + "time": "2020-04-13T13:17:36+00:00" + }, + { + "name": "guzzlehttp/guzzle", + "version": "7.3.0", + "source": { + "type": "git", + "url": "https://github.com/guzzle/guzzle.git", + "reference": "7008573787b430c1c1f650e3722d9bba59967628" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/guzzle/guzzle/zipball/7008573787b430c1c1f650e3722d9bba59967628", + "reference": "7008573787b430c1c1f650e3722d9bba59967628", + "shasum": "" + }, + "require": { + "ext-json": "*", + "guzzlehttp/promises": "^1.4", + "guzzlehttp/psr7": "^1.7 || ^2.0", + "php": "^7.2.5 || ^8.0", + "psr/http-client": "^1.0" + }, + "provide": { + "psr/http-client-implementation": "1.0" + }, + "require-dev": { + "bamarni/composer-bin-plugin": "^1.4.1", "ext-curl": "*", - "phpunit/phpunit": "^4.8.35 || ^5.7 || ^6.4 || ^7.0", - "psr/log": "^1.0" + "php-http/client-integration-tests": "^3.0", + "phpunit/phpunit": "^8.5.5 || ^9.3.5", + "psr/log": "^1.1" }, "suggest": { + "ext-curl": "Required for CURL handler support", + "ext-intl": "Required for Internationalized Domain Name (IDN) support", "psr/log": "Required for using the Log middleware" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "6.3-dev" + "dev-master": "7.3-dev" } }, "autoload": { - "files": [ - "src/functions_include.php" - ], "psr-4": { "GuzzleHttp\\": "src/" - } + }, + "files": [ + "src/functions_include.php" + ] }, "notification-url": "https://packagist.org/downloads/", "license": [ @@ -158,6 +252,11 @@ "name": "Michael Dowling", "email": "mtdowling@gmail.com", "homepage": "https://github.com/mtdowling" + }, + { + "name": "Márk Sági-Kazár", + "email": "mark.sagikazar@gmail.com", + "homepage": "https://sagikazarmark.hu" } ], "description": "Guzzle is a PHP HTTP client library", @@ -168,30 +267,54 @@ "framework", "http", "http client", + "psr-18", + "psr-7", "rest", "web service" ], - "time": "2018-04-22T15:46:56+00:00" + "support": { + "issues": "https://github.com/guzzle/guzzle/issues", + "source": "https://github.com/guzzle/guzzle/tree/7.3.0" + }, + "funding": [ + { + "url": "https://github.com/GrahamCampbell", + "type": "github" + }, + { + "url": "https://github.com/Nyholm", + "type": "github" + }, + { + "url": "https://github.com/alexeyshockov", + "type": "github" + }, + { + "url": "https://github.com/gmponos", + "type": "github" + } + ], + "time": "2021-03-23T11:33:13+00:00" }, { "name": "guzzlehttp/promises", - "version": "v1.3.1", + "version": "1.4.1", "source": { "type": "git", "url": "https://github.com/guzzle/promises.git", - "reference": "a59da6cf61d80060647ff4d3eb2c03a2bc694646" + "reference": "8e7d04f1f6450fef59366c399cfad4b9383aa30d" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/guzzle/promises/zipball/a59da6cf61d80060647ff4d3eb2c03a2bc694646", - "reference": "a59da6cf61d80060647ff4d3eb2c03a2bc694646", + "url": "https://api.github.com/repos/guzzle/promises/zipball/8e7d04f1f6450fef59366c399cfad4b9383aa30d", + "reference": "8e7d04f1f6450fef59366c399cfad4b9383aa30d", "shasum": "" }, "require": { - "php": ">=5.5.0" + "php": ">=5.5" }, "require-dev": { - "phpunit/phpunit": "^4.0" + "symfony/phpunit-bridge": "^4.4 || ^5.1" }, "type": "library", "extra": { @@ -222,37 +345,45 @@ "keywords": [ "promise" ], - "time": "2016-12-20T10:07:11+00:00" + "support": { + "issues": "https://github.com/guzzle/promises/issues", + "source": "https://github.com/guzzle/promises/tree/1.4.1" + }, + "time": "2021-03-07T09:25:29+00:00" }, { "name": "guzzlehttp/psr7", - "version": "1.5.2", + "version": "1.8.1", "source": { "type": "git", "url": "https://github.com/guzzle/psr7.git", - "reference": "9f83dded91781a01c63574e387eaa769be769115" + "reference": "35ea11d335fd638b5882ff1725228b3d35496ab1" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/guzzle/psr7/zipball/9f83dded91781a01c63574e387eaa769be769115", - "reference": "9f83dded91781a01c63574e387eaa769be769115", + "url": "https://api.github.com/repos/guzzle/psr7/zipball/35ea11d335fd638b5882ff1725228b3d35496ab1", + "reference": "35ea11d335fd638b5882ff1725228b3d35496ab1", "shasum": "" }, "require": { "php": ">=5.4.0", "psr/http-message": "~1.0", - "ralouphie/getallheaders": "^2.0.5" + "ralouphie/getallheaders": "^2.0.5 || ^3.0.0" }, "provide": { "psr/http-message-implementation": "1.0" }, "require-dev": { - "phpunit/phpunit": "~4.8.36 || ^5.7.27 || ^6.5.8" + "ext-zlib": "*", + "phpunit/phpunit": "~4.8.36 || ^5.7.27 || ^6.5.14 || ^7.5.20 || ^8.5.8 || ^9.3.10" + }, + "suggest": { + "laminas/laminas-httphandlerrunner": "Emit PSR-7 responses" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "1.5-dev" + "dev-master": "1.7-dev" } }, "autoload": { @@ -289,24 +420,87 @@ "uri", "url" ], - "time": "2018-12-04T20:46:45+00:00" + "support": { + "issues": "https://github.com/guzzle/psr7/issues", + "source": "https://github.com/guzzle/psr7/tree/1.8.1" + }, + "time": "2021-03-21T16:25:00+00:00" }, { - "name": "myclabs/deep-copy", - "version": "1.8.1", + "name": "kornrunner/dbunit", + "version": "6.0.0", "source": { "type": "git", - "url": "https://github.com/myclabs/DeepCopy.git", - "reference": "3e01bdad3e18354c3dce54466b7fbe33a9f9f7f8" + "url": "https://github.com/kornrunner/dbunit.git", + "reference": "6e99848da3cc2cb0fd8f9e2a0a657390c8b34b79" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/myclabs/DeepCopy/zipball/3e01bdad3e18354c3dce54466b7fbe33a9f9f7f8", - "reference": "3e01bdad3e18354c3dce54466b7fbe33a9f9f7f8", + "url": "https://api.github.com/repos/kornrunner/dbunit/zipball/6e99848da3cc2cb0fd8f9e2a0a657390c8b34b79", + "reference": "6e99848da3cc2cb0fd8f9e2a0a657390c8b34b79", "shasum": "" }, "require": { - "php": "^7.1" + "ext-pdo": "*", + "ext-simplexml": "*", + "php": "^7.3 || ^8.0", + "phpunit/phpunit": "^8.2 || ^9.0", + "symfony/yaml": "^3.0 || ^4.0 || ^5.0" + }, + "replace": { + "phpunit/dbunit": "self.version" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "4.1-dev" + } + }, + "autoload": { + "classmap": [ + "src/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "BSD-3-Clause" + ], + "authors": [ + { + "name": "Sebastian Bergmann", + "email": "sebastian@phpunit.de", + "role": "lead" + } + ], + "description": "PHPUnit extension for database interaction testing", + "homepage": "https://github.com/sebastianbergmann/dbunit/", + "keywords": [ + "database", + "testing", + "xunit" + ], + "support": { + "issues": "https://github.com/sebastianbergmann/dbunit/issues", + "source": "https://github.com/kornrunner/dbunit/tree/6.0.0" + }, + "time": "2020-12-07T12:07:27+00:00" + }, + { + "name": "myclabs/deep-copy", + "version": "1.10.2", + "source": { + "type": "git", + "url": "https://github.com/myclabs/DeepCopy.git", + "reference": "776f831124e9c62e1a2c601ecc52e776d8bb7220" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/myclabs/DeepCopy/zipball/776f831124e9c62e1a2c601ecc52e776d8bb7220", + "reference": "776f831124e9c62e1a2c601ecc52e776d8bb7220", + "shasum": "" + }, + "require": { + "php": "^7.1 || ^8.0" }, "replace": { "myclabs/deep-copy": "self.version" @@ -337,39 +531,211 @@ "object", "object graph" ], - "time": "2018-06-11T23:09:50+00:00" + "support": { + "issues": "https://github.com/myclabs/DeepCopy/issues", + "source": "https://github.com/myclabs/DeepCopy/tree/1.10.2" + }, + "funding": [ + { + "url": "https://tidelift.com/funding/github/packagist/myclabs/deep-copy", + "type": "tidelift" + } + ], + "time": "2020-11-13T09:40:50+00:00" }, { - "name": "phpdocumentor/reflection-common", - "version": "1.0.1", + "name": "nikic/php-parser", + "version": "v4.10.4", "source": { "type": "git", - "url": "https://github.com/phpDocumentor/ReflectionCommon.git", - "reference": "21bdeb5f65d7ebf9f43b1b25d404f87deab5bfb6" + "url": "https://github.com/nikic/PHP-Parser.git", + "reference": "c6d052fc58cb876152f89f532b95a8d7907e7f0e" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/phpDocumentor/ReflectionCommon/zipball/21bdeb5f65d7ebf9f43b1b25d404f87deab5bfb6", - "reference": "21bdeb5f65d7ebf9f43b1b25d404f87deab5bfb6", + "url": "https://api.github.com/repos/nikic/PHP-Parser/zipball/c6d052fc58cb876152f89f532b95a8d7907e7f0e", + "reference": "c6d052fc58cb876152f89f532b95a8d7907e7f0e", "shasum": "" }, "require": { - "php": ">=5.5" + "ext-tokenizer": "*", + "php": ">=7.0" }, "require-dev": { - "phpunit/phpunit": "^4.6" + "ircmaxell/php-yacc": "^0.0.7", + "phpunit/phpunit": "^6.5 || ^7.0 || ^8.0 || ^9.0" }, + "bin": [ + "bin/php-parse" + ], "type": "library", "extra": { "branch-alias": { - "dev-master": "1.0.x-dev" + "dev-master": "4.9-dev" } }, "autoload": { "psr-4": { - "phpDocumentor\\Reflection\\": [ - "src" - ] + "PhpParser\\": "lib/PhpParser" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "BSD-3-Clause" + ], + "authors": [ + { + "name": "Nikita Popov" + } + ], + "description": "A PHP parser written in PHP", + "keywords": [ + "parser", + "php" + ], + "support": { + "issues": "https://github.com/nikic/PHP-Parser/issues", + "source": "https://github.com/nikic/PHP-Parser/tree/v4.10.4" + }, + "time": "2020-12-20T10:01:03+00:00" + }, + { + "name": "phar-io/manifest", + "version": "2.0.1", + "source": { + "type": "git", + "url": "https://github.com/phar-io/manifest.git", + "reference": "85265efd3af7ba3ca4b2a2c34dbfc5788dd29133" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/phar-io/manifest/zipball/85265efd3af7ba3ca4b2a2c34dbfc5788dd29133", + "reference": "85265efd3af7ba3ca4b2a2c34dbfc5788dd29133", + "shasum": "" + }, + "require": { + "ext-dom": "*", + "ext-phar": "*", + "ext-xmlwriter": "*", + "phar-io/version": "^3.0.1", + "php": "^7.2 || ^8.0" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "2.0.x-dev" + } + }, + "autoload": { + "classmap": [ + "src/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "BSD-3-Clause" + ], + "authors": [ + { + "name": "Arne Blankerts", + "email": "arne@blankerts.de", + "role": "Developer" + }, + { + "name": "Sebastian Heuer", + "email": "sebastian@phpeople.de", + "role": "Developer" + }, + { + "name": "Sebastian Bergmann", + "email": "sebastian@phpunit.de", + "role": "Developer" + } + ], + "description": "Component for reading phar.io manifest information from a PHP Archive (PHAR)", + "support": { + "issues": "https://github.com/phar-io/manifest/issues", + "source": "https://github.com/phar-io/manifest/tree/master" + }, + "time": "2020-06-27T14:33:11+00:00" + }, + { + "name": "phar-io/version", + "version": "3.1.0", + "source": { + "type": "git", + "url": "https://github.com/phar-io/version.git", + "reference": "bae7c545bef187884426f042434e561ab1ddb182" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/phar-io/version/zipball/bae7c545bef187884426f042434e561ab1ddb182", + "reference": "bae7c545bef187884426f042434e561ab1ddb182", + "shasum": "" + }, + "require": { + "php": "^7.2 || ^8.0" + }, + "type": "library", + "autoload": { + "classmap": [ + "src/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "BSD-3-Clause" + ], + "authors": [ + { + "name": "Arne Blankerts", + "email": "arne@blankerts.de", + "role": "Developer" + }, + { + "name": "Sebastian Heuer", + "email": "sebastian@phpeople.de", + "role": "Developer" + }, + { + "name": "Sebastian Bergmann", + "email": "sebastian@phpunit.de", + "role": "Developer" + } + ], + "description": "Library for handling version information and constraints", + "support": { + "issues": "https://github.com/phar-io/version/issues", + "source": "https://github.com/phar-io/version/tree/3.1.0" + }, + "time": "2021-02-23T14:00:09+00:00" + }, + { + "name": "phpdocumentor/reflection-common", + "version": "2.2.0", + "source": { + "type": "git", + "url": "https://github.com/phpDocumentor/ReflectionCommon.git", + "reference": "1d01c49d4ed62f25aa84a747ad35d5a16924662b" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/phpDocumentor/ReflectionCommon/zipball/1d01c49d4ed62f25aa84a747ad35d5a16924662b", + "reference": "1d01c49d4ed62f25aa84a747ad35d5a16924662b", + "shasum": "" + }, + "require": { + "php": "^7.2 || ^8.0" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-2.x": "2.x-dev" + } + }, + "autoload": { + "psr-4": { + "phpDocumentor\\Reflection\\": "src/" } }, "notification-url": "https://packagist.org/downloads/", @@ -391,44 +757,45 @@ "reflection", "static analysis" ], - "time": "2017-09-11T18:02:19+00:00" + "support": { + "issues": "https://github.com/phpDocumentor/ReflectionCommon/issues", + "source": "https://github.com/phpDocumentor/ReflectionCommon/tree/2.x" + }, + "time": "2020-06-27T09:03:43+00:00" }, { "name": "phpdocumentor/reflection-docblock", - "version": "4.3.0", + "version": "5.2.2", "source": { "type": "git", "url": "https://github.com/phpDocumentor/ReflectionDocBlock.git", - "reference": "94fd0001232e47129dd3504189fa1c7225010d08" + "reference": "069a785b2141f5bcf49f3e353548dc1cce6df556" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/phpDocumentor/ReflectionDocBlock/zipball/94fd0001232e47129dd3504189fa1c7225010d08", - "reference": "94fd0001232e47129dd3504189fa1c7225010d08", + "url": "https://api.github.com/repos/phpDocumentor/ReflectionDocBlock/zipball/069a785b2141f5bcf49f3e353548dc1cce6df556", + "reference": "069a785b2141f5bcf49f3e353548dc1cce6df556", "shasum": "" }, "require": { - "php": "^7.0", - "phpdocumentor/reflection-common": "^1.0.0", - "phpdocumentor/type-resolver": "^0.4.0", - "webmozart/assert": "^1.0" + "ext-filter": "*", + "php": "^7.2 || ^8.0", + "phpdocumentor/reflection-common": "^2.2", + "phpdocumentor/type-resolver": "^1.3", + "webmozart/assert": "^1.9.1" }, "require-dev": { - "doctrine/instantiator": "~1.0.5", - "mockery/mockery": "^1.0", - "phpunit/phpunit": "^6.4" + "mockery/mockery": "~1.3.2" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "4.x-dev" + "dev-master": "5.x-dev" } }, "autoload": { "psr-4": { - "phpDocumentor\\Reflection\\": [ - "src/" - ] + "phpDocumentor\\Reflection\\": "src" } }, "notification-url": "https://packagist.org/downloads/", @@ -439,44 +806,49 @@ { "name": "Mike van Riel", "email": "me@mikevanriel.com" + }, + { + "name": "Jaap van Otterdijk", + "email": "account@ijaap.nl" } ], "description": "With this component, a library can provide support for annotations via DocBlocks or otherwise retrieve information that is embedded in a DocBlock.", - "time": "2017-11-30T07:14:17+00:00" + "support": { + "issues": "https://github.com/phpDocumentor/ReflectionDocBlock/issues", + "source": "https://github.com/phpDocumentor/ReflectionDocBlock/tree/master" + }, + "time": "2020-09-03T19:13:55+00:00" }, { "name": "phpdocumentor/type-resolver", - "version": "0.4.0", + "version": "1.4.0", "source": { "type": "git", "url": "https://github.com/phpDocumentor/TypeResolver.git", - "reference": "9c977708995954784726e25d0cd1dddf4e65b0f7" + "reference": "6a467b8989322d92aa1c8bf2bebcc6e5c2ba55c0" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/phpDocumentor/TypeResolver/zipball/9c977708995954784726e25d0cd1dddf4e65b0f7", - "reference": "9c977708995954784726e25d0cd1dddf4e65b0f7", + "url": "https://api.github.com/repos/phpDocumentor/TypeResolver/zipball/6a467b8989322d92aa1c8bf2bebcc6e5c2ba55c0", + "reference": "6a467b8989322d92aa1c8bf2bebcc6e5c2ba55c0", "shasum": "" }, "require": { - "php": "^5.5 || ^7.0", - "phpdocumentor/reflection-common": "^1.0" + "php": "^7.2 || ^8.0", + "phpdocumentor/reflection-common": "^2.0" }, "require-dev": { - "mockery/mockery": "^0.9.4", - "phpunit/phpunit": "^5.2||^4.8.24" + "ext-tokenizer": "*" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "1.0.x-dev" + "dev-1.x": "1.x-dev" } }, "autoload": { "psr-4": { - "phpDocumentor\\Reflection\\": [ - "src/" - ] + "phpDocumentor\\Reflection\\": "src" } }, "notification-url": "https://packagist.org/downloads/", @@ -489,47 +861,57 @@ "email": "me@mikevanriel.com" } ], - "time": "2017-07-14T14:27:02+00:00" + "description": "A PSR-5 based resolver of Class names, Types and Structural Element Names", + "support": { + "issues": "https://github.com/phpDocumentor/TypeResolver/issues", + "source": "https://github.com/phpDocumentor/TypeResolver/tree/1.4.0" + }, + "time": "2020-09-17T18:55:26+00:00" }, { "name": "phpoption/phpoption", - "version": "1.5.0", + "version": "1.7.5", "source": { "type": "git", "url": "https://github.com/schmittjoh/php-option.git", - "reference": "94e644f7d2051a5f0fcf77d81605f152eecff0ed" + "reference": "994ecccd8f3283ecf5ac33254543eb0ac946d525" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/schmittjoh/php-option/zipball/94e644f7d2051a5f0fcf77d81605f152eecff0ed", - "reference": "94e644f7d2051a5f0fcf77d81605f152eecff0ed", + "url": "https://api.github.com/repos/schmittjoh/php-option/zipball/994ecccd8f3283ecf5ac33254543eb0ac946d525", + "reference": "994ecccd8f3283ecf5ac33254543eb0ac946d525", "shasum": "" }, "require": { - "php": ">=5.3.0" + "php": "^5.5.9 || ^7.0 || ^8.0" }, "require-dev": { - "phpunit/phpunit": "4.7.*" + "bamarni/composer-bin-plugin": "^1.4.1", + "phpunit/phpunit": "^4.8.35 || ^5.7.27 || ^6.5.6 || ^7.0 || ^8.0 || ^9.0" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "1.3-dev" + "dev-master": "1.7-dev" } }, "autoload": { - "psr-0": { - "PhpOption\\": "src/" + "psr-4": { + "PhpOption\\": "src/PhpOption/" } }, "notification-url": "https://packagist.org/downloads/", "license": [ - "Apache2" + "Apache-2.0" ], "authors": [ { "name": "Johannes M. Schmitt", "email": "schmittjoh@gmail.com" + }, + { + "name": "Graham Campbell", + "email": "graham@alt-three.com" } ], "description": "Option Type for PHP", @@ -539,42 +921,56 @@ "php", "type" ], - "time": "2015-07-25T16:39:46+00:00" + "support": { + "issues": "https://github.com/schmittjoh/php-option/issues", + "source": "https://github.com/schmittjoh/php-option/tree/1.7.5" + }, + "funding": [ + { + "url": "https://github.com/GrahamCampbell", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/phpoption/phpoption", + "type": "tidelift" + } + ], + "time": "2020-07-20T17:29:33+00:00" }, { "name": "phpspec/prophecy", - "version": "1.8.0", + "version": "1.13.0", "source": { "type": "git", "url": "https://github.com/phpspec/prophecy.git", - "reference": "4ba436b55987b4bf311cb7c6ba82aa528aac0a06" + "reference": "be1996ed8adc35c3fd795488a653f4b518be70ea" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/phpspec/prophecy/zipball/4ba436b55987b4bf311cb7c6ba82aa528aac0a06", - "reference": "4ba436b55987b4bf311cb7c6ba82aa528aac0a06", + "url": "https://api.github.com/repos/phpspec/prophecy/zipball/be1996ed8adc35c3fd795488a653f4b518be70ea", + "reference": "be1996ed8adc35c3fd795488a653f4b518be70ea", "shasum": "" }, "require": { - "doctrine/instantiator": "^1.0.2", - "php": "^5.3|^7.0", - "phpdocumentor/reflection-docblock": "^2.0|^3.0.2|^4.0", - "sebastian/comparator": "^1.1|^2.0|^3.0", - "sebastian/recursion-context": "^1.0|^2.0|^3.0" + "doctrine/instantiator": "^1.2", + "php": "^7.2 || ~8.0, <8.1", + "phpdocumentor/reflection-docblock": "^5.2", + "sebastian/comparator": "^3.0 || ^4.0", + "sebastian/recursion-context": "^3.0 || ^4.0" }, "require-dev": { - "phpspec/phpspec": "^2.5|^3.2", - "phpunit/phpunit": "^4.8.35 || ^5.7 || ^6.5 || ^7.1" + "phpspec/phpspec": "^6.0", + "phpunit/phpunit": "^8.0 || ^9.0" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "1.8.x-dev" + "dev-master": "1.11.x-dev" } }, "autoload": { - "psr-0": { - "Prophecy\\": "src/" + "psr-4": { + "Prophecy\\": "src/Prophecy" } }, "notification-url": "https://packagist.org/downloads/", @@ -602,100 +998,52 @@ "spy", "stub" ], - "time": "2018-08-05T17:53:17+00:00" - }, - { - "name": "phpunit/dbunit", - "version": "2.0.3", - "source": { - "type": "git", - "url": "https://github.com/sebastianbergmann/dbunit.git", - "reference": "5c35d74549c21ba55d0ea74ba89d191a51f8cf25" + "support": { + "issues": "https://github.com/phpspec/prophecy/issues", + "source": "https://github.com/phpspec/prophecy/tree/1.13.0" }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/dbunit/zipball/5c35d74549c21ba55d0ea74ba89d191a51f8cf25", - "reference": "5c35d74549c21ba55d0ea74ba89d191a51f8cf25", - "shasum": "" - }, - "require": { - "ext-pdo": "*", - "ext-simplexml": "*", - "php": "^5.4 || ^7.0", - "phpunit/phpunit": "^4.0 || ^5.0 || ^6.0", - "symfony/yaml": "^2.1 || ^3.0" - }, - "bin": [ - "dbunit" - ], - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "2.0.x-dev" - } - }, - "autoload": { - "classmap": [ - "src/" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], - "authors": [ - { - "name": "Sebastian Bergmann", - "email": "sb@sebastian-bergmann.de", - "role": "lead" - } - ], - "description": "DbUnit port for PHP/PHPUnit to support database interaction testing.", - "homepage": "https://github.com/sebastianbergmann/dbunit/", - "keywords": [ - "database", - "testing", - "xunit" - ], - "abandoned": true, - "time": "2016-12-02T14:39:14+00:00" + "time": "2021-03-17T13:42:18+00:00" }, { "name": "phpunit/php-code-coverage", - "version": "4.0.8", + "version": "9.2.6", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/php-code-coverage.git", - "reference": "ef7b2f56815df854e66ceaee8ebe9393ae36a40d" + "reference": "f6293e1b30a2354e8428e004689671b83871edde" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/php-code-coverage/zipball/ef7b2f56815df854e66ceaee8ebe9393ae36a40d", - "reference": "ef7b2f56815df854e66ceaee8ebe9393ae36a40d", + "url": "https://api.github.com/repos/sebastianbergmann/php-code-coverage/zipball/f6293e1b30a2354e8428e004689671b83871edde", + "reference": "f6293e1b30a2354e8428e004689671b83871edde", "shasum": "" }, "require": { "ext-dom": "*", + "ext-libxml": "*", "ext-xmlwriter": "*", - "php": "^5.6 || ^7.0", - "phpunit/php-file-iterator": "^1.3", - "phpunit/php-text-template": "^1.2", - "phpunit/php-token-stream": "^1.4.2 || ^2.0", - "sebastian/code-unit-reverse-lookup": "^1.0", - "sebastian/environment": "^1.3.2 || ^2.0", - "sebastian/version": "^1.0 || ^2.0" + "nikic/php-parser": "^4.10.2", + "php": ">=7.3", + "phpunit/php-file-iterator": "^3.0.3", + "phpunit/php-text-template": "^2.0.2", + "sebastian/code-unit-reverse-lookup": "^2.0.2", + "sebastian/complexity": "^2.0", + "sebastian/environment": "^5.1.2", + "sebastian/lines-of-code": "^1.0.3", + "sebastian/version": "^3.0.1", + "theseer/tokenizer": "^1.2.0" }, "require-dev": { - "ext-xdebug": "^2.1.4", - "phpunit/phpunit": "^5.7" + "phpunit/phpunit": "^9.3" }, "suggest": { - "ext-xdebug": "^2.5.1" + "ext-pcov": "*", + "ext-xdebug": "*" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "4.0.x-dev" + "dev-master": "9.2-dev" } }, "autoload": { @@ -710,7 +1058,7 @@ "authors": [ { "name": "Sebastian Bergmann", - "email": "sb@sebastian-bergmann.de", + "email": "sebastian@phpunit.de", "role": "lead" } ], @@ -721,29 +1069,42 @@ "testing", "xunit" ], - "time": "2017-04-02T07:44:40+00:00" + "support": { + "issues": "https://github.com/sebastianbergmann/php-code-coverage/issues", + "source": "https://github.com/sebastianbergmann/php-code-coverage/tree/9.2.6" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } + ], + "time": "2021-03-28T07:26:59+00:00" }, { "name": "phpunit/php-file-iterator", - "version": "1.4.5", + "version": "3.0.5", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/php-file-iterator.git", - "reference": "730b01bc3e867237eaac355e06a36b85dd93a8b4" + "reference": "aa4be8575f26070b100fccb67faabb28f21f66f8" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/php-file-iterator/zipball/730b01bc3e867237eaac355e06a36b85dd93a8b4", - "reference": "730b01bc3e867237eaac355e06a36b85dd93a8b4", + "url": "https://api.github.com/repos/sebastianbergmann/php-file-iterator/zipball/aa4be8575f26070b100fccb67faabb28f21f66f8", + "reference": "aa4be8575f26070b100fccb67faabb28f21f66f8", "shasum": "" }, "require": { - "php": ">=5.3.3" + "php": ">=7.3" + }, + "require-dev": { + "phpunit/phpunit": "^9.3" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "1.4.x-dev" + "dev-master": "3.0-dev" } }, "autoload": { @@ -758,7 +1119,7 @@ "authors": [ { "name": "Sebastian Bergmann", - "email": "sb@sebastian-bergmann.de", + "email": "sebastian@phpunit.de", "role": "lead" } ], @@ -768,26 +1129,107 @@ "filesystem", "iterator" ], - "time": "2017-11-27T13:52:08+00:00" + "support": { + "issues": "https://github.com/sebastianbergmann/php-file-iterator/issues", + "source": "https://github.com/sebastianbergmann/php-file-iterator/tree/3.0.5" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } + ], + "time": "2020-09-28T05:57:25+00:00" }, { - "name": "phpunit/php-text-template", - "version": "1.2.1", + "name": "phpunit/php-invoker", + "version": "3.1.1", "source": { "type": "git", - "url": "https://github.com/sebastianbergmann/php-text-template.git", - "reference": "31f8b717e51d9a2afca6c9f046f5d69fc27c8686" + "url": "https://github.com/sebastianbergmann/php-invoker.git", + "reference": "5a10147d0aaf65b58940a0b72f71c9ac0423cc67" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/php-text-template/zipball/31f8b717e51d9a2afca6c9f046f5d69fc27c8686", - "reference": "31f8b717e51d9a2afca6c9f046f5d69fc27c8686", + "url": "https://api.github.com/repos/sebastianbergmann/php-invoker/zipball/5a10147d0aaf65b58940a0b72f71c9ac0423cc67", + "reference": "5a10147d0aaf65b58940a0b72f71c9ac0423cc67", "shasum": "" }, "require": { - "php": ">=5.3.3" + "php": ">=7.3" + }, + "require-dev": { + "ext-pcntl": "*", + "phpunit/phpunit": "^9.3" + }, + "suggest": { + "ext-pcntl": "*" }, "type": "library", + "extra": { + "branch-alias": { + "dev-master": "3.1-dev" + } + }, + "autoload": { + "classmap": [ + "src/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "BSD-3-Clause" + ], + "authors": [ + { + "name": "Sebastian Bergmann", + "email": "sebastian@phpunit.de", + "role": "lead" + } + ], + "description": "Invoke callables with a timeout", + "homepage": "https://github.com/sebastianbergmann/php-invoker/", + "keywords": [ + "process" + ], + "support": { + "issues": "https://github.com/sebastianbergmann/php-invoker/issues", + "source": "https://github.com/sebastianbergmann/php-invoker/tree/3.1.1" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } + ], + "time": "2020-09-28T05:58:55+00:00" + }, + { + "name": "phpunit/php-text-template", + "version": "2.0.4", + "source": { + "type": "git", + "url": "https://github.com/sebastianbergmann/php-text-template.git", + "reference": "5da5f67fc95621df9ff4c4e5a84d6a8a2acf7c28" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/sebastianbergmann/php-text-template/zipball/5da5f67fc95621df9ff4c4e5a84d6a8a2acf7c28", + "reference": "5da5f67fc95621df9ff4c4e5a84d6a8a2acf7c28", + "shasum": "" + }, + "require": { + "php": ">=7.3" + }, + "require-dev": { + "phpunit/phpunit": "^9.3" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "2.0-dev" + } + }, "autoload": { "classmap": [ "src/" @@ -809,32 +1251,42 @@ "keywords": [ "template" ], - "time": "2015-06-21T13:50:34+00:00" + "support": { + "issues": "https://github.com/sebastianbergmann/php-text-template/issues", + "source": "https://github.com/sebastianbergmann/php-text-template/tree/2.0.4" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } + ], + "time": "2020-10-26T05:33:50+00:00" }, { "name": "phpunit/php-timer", - "version": "1.0.9", + "version": "5.0.3", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/php-timer.git", - "reference": "3dcf38ca72b158baf0bc245e9184d3fdffa9c46f" + "reference": "5a63ce20ed1b5bf577850e2c4e87f4aa902afbd2" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/php-timer/zipball/3dcf38ca72b158baf0bc245e9184d3fdffa9c46f", - "reference": "3dcf38ca72b158baf0bc245e9184d3fdffa9c46f", + "url": "https://api.github.com/repos/sebastianbergmann/php-timer/zipball/5a63ce20ed1b5bf577850e2c4e87f4aa902afbd2", + "reference": "5a63ce20ed1b5bf577850e2c4e87f4aa902afbd2", "shasum": "" }, "require": { - "php": "^5.3.3 || ^7.0" + "php": ">=7.3" }, "require-dev": { - "phpunit/phpunit": "^4.8.35 || ^5.7 || ^6.0" + "phpunit/phpunit": "^9.3" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "1.0-dev" + "dev-master": "5.0-dev" } }, "autoload": { @@ -849,7 +1301,7 @@ "authors": [ { "name": "Sebastian Bergmann", - "email": "sb@sebastian-bergmann.de", + "email": "sebastian@phpunit.de", "role": "lead" } ], @@ -858,104 +1310,69 @@ "keywords": [ "timer" ], - "time": "2017-02-26T11:10:40+00:00" - }, - { - "name": "phpunit/php-token-stream", - "version": "2.0.2", - "source": { - "type": "git", - "url": "https://github.com/sebastianbergmann/php-token-stream.git", - "reference": "791198a2c6254db10131eecfe8c06670700904db" + "support": { + "issues": "https://github.com/sebastianbergmann/php-timer/issues", + "source": "https://github.com/sebastianbergmann/php-timer/tree/5.0.3" }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/php-token-stream/zipball/791198a2c6254db10131eecfe8c06670700904db", - "reference": "791198a2c6254db10131eecfe8c06670700904db", - "shasum": "" - }, - "require": { - "ext-tokenizer": "*", - "php": "^7.0" - }, - "require-dev": { - "phpunit/phpunit": "^6.2.4" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "2.0-dev" - } - }, - "autoload": { - "classmap": [ - "src/" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], - "authors": [ + "funding": [ { - "name": "Sebastian Bergmann", - "email": "sebastian@phpunit.de" + "url": "https://github.com/sebastianbergmann", + "type": "github" } ], - "description": "Wrapper around PHP's tokenizer extension.", - "homepage": "https://github.com/sebastianbergmann/php-token-stream/", - "keywords": [ - "tokenizer" - ], - "time": "2017-11-27T05:48:46+00:00" + "time": "2020-10-26T13:16:10+00:00" }, { "name": "phpunit/phpunit", - "version": "5.7.27", + "version": "9.5.4", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/phpunit.git", - "reference": "b7803aeca3ccb99ad0a506fa80b64cd6a56bbc0c" + "reference": "c73c6737305e779771147af66c96ca6a7ed8a741" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/phpunit/zipball/b7803aeca3ccb99ad0a506fa80b64cd6a56bbc0c", - "reference": "b7803aeca3ccb99ad0a506fa80b64cd6a56bbc0c", + "url": "https://api.github.com/repos/sebastianbergmann/phpunit/zipball/c73c6737305e779771147af66c96ca6a7ed8a741", + "reference": "c73c6737305e779771147af66c96ca6a7ed8a741", "shasum": "" }, "require": { + "doctrine/instantiator": "^1.3.1", "ext-dom": "*", "ext-json": "*", "ext-libxml": "*", "ext-mbstring": "*", "ext-xml": "*", - "myclabs/deep-copy": "~1.3", - "php": "^5.6 || ^7.0", - "phpspec/prophecy": "^1.6.2", - "phpunit/php-code-coverage": "^4.0.4", - "phpunit/php-file-iterator": "~1.4", - "phpunit/php-text-template": "~1.2", - "phpunit/php-timer": "^1.0.6", - "phpunit/phpunit-mock-objects": "^3.2", - "sebastian/comparator": "^1.2.4", - "sebastian/diff": "^1.4.3", - "sebastian/environment": "^1.3.4 || ^2.0", - "sebastian/exporter": "~2.0", - "sebastian/global-state": "^1.1", - "sebastian/object-enumerator": "~2.0", - "sebastian/resource-operations": "~1.0", - "sebastian/version": "^1.0.6|^2.0.1", - "symfony/yaml": "~2.1|~3.0|~4.0" - }, - "conflict": { - "phpdocumentor/reflection-docblock": "3.0.2" + "ext-xmlwriter": "*", + "myclabs/deep-copy": "^1.10.1", + "phar-io/manifest": "^2.0.1", + "phar-io/version": "^3.0.2", + "php": ">=7.3", + "phpspec/prophecy": "^1.12.1", + "phpunit/php-code-coverage": "^9.2.3", + "phpunit/php-file-iterator": "^3.0.5", + "phpunit/php-invoker": "^3.1.1", + "phpunit/php-text-template": "^2.0.3", + "phpunit/php-timer": "^5.0.2", + "sebastian/cli-parser": "^1.0.1", + "sebastian/code-unit": "^1.0.6", + "sebastian/comparator": "^4.0.5", + "sebastian/diff": "^4.0.3", + "sebastian/environment": "^5.1.3", + "sebastian/exporter": "^4.0.3", + "sebastian/global-state": "^5.0.1", + "sebastian/object-enumerator": "^4.0.3", + "sebastian/resource-operations": "^3.0.3", + "sebastian/type": "^2.3", + "sebastian/version": "^3.0.2" }, "require-dev": { - "ext-pdo": "*" + "ext-pdo": "*", + "phpspec/prophecy-phpunit": "^2.0.1" }, "suggest": { - "ext-xdebug": "*", - "phpunit/php-invoker": "~1.1" + "ext-soap": "*", + "ext-xdebug": "*" }, "bin": [ "phpunit" @@ -963,12 +1380,15 @@ "type": "library", "extra": { "branch-alias": { - "dev-master": "5.7.x-dev" + "dev-master": "9.5-dev" } }, "autoload": { "classmap": [ "src/" + ], + "files": [ + "src/Framework/Assert/Functions.php" ] }, "notification-url": "https://packagist.org/downloads/", @@ -989,67 +1409,73 @@ "testing", "xunit" ], - "time": "2018-02-01T05:50:59+00:00" + "support": { + "issues": "https://github.com/sebastianbergmann/phpunit/issues", + "source": "https://github.com/sebastianbergmann/phpunit/tree/9.5.4" + }, + "funding": [ + { + "url": "https://phpunit.de/donate.html", + "type": "custom" + }, + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } + ], + "time": "2021-03-23T07:16:29+00:00" }, { - "name": "phpunit/phpunit-mock-objects", - "version": "3.4.4", + "name": "psr/http-client", + "version": "1.0.1", "source": { "type": "git", - "url": "https://github.com/sebastianbergmann/phpunit-mock-objects.git", - "reference": "a23b761686d50a560cc56233b9ecf49597cc9118" + "url": "https://github.com/php-fig/http-client.git", + "reference": "2dfb5f6c5eff0e91e20e913f8c5452ed95b86621" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/phpunit-mock-objects/zipball/a23b761686d50a560cc56233b9ecf49597cc9118", - "reference": "a23b761686d50a560cc56233b9ecf49597cc9118", + "url": "https://api.github.com/repos/php-fig/http-client/zipball/2dfb5f6c5eff0e91e20e913f8c5452ed95b86621", + "reference": "2dfb5f6c5eff0e91e20e913f8c5452ed95b86621", "shasum": "" }, "require": { - "doctrine/instantiator": "^1.0.2", - "php": "^5.6 || ^7.0", - "phpunit/php-text-template": "^1.2", - "sebastian/exporter": "^1.2 || ^2.0" - }, - "conflict": { - "phpunit/phpunit": "<5.4.0" - }, - "require-dev": { - "phpunit/phpunit": "^5.4" - }, - "suggest": { - "ext-soap": "*" + "php": "^7.0 || ^8.0", + "psr/http-message": "^1.0" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "3.2.x-dev" + "dev-master": "1.0.x-dev" } }, "autoload": { - "classmap": [ - "src/" - ] + "psr-4": { + "Psr\\Http\\Client\\": "src/" + } }, "notification-url": "https://packagist.org/downloads/", "license": [ - "BSD-3-Clause" + "MIT" ], "authors": [ { - "name": "Sebastian Bergmann", - "email": "sb@sebastian-bergmann.de", - "role": "lead" + "name": "PHP-FIG", + "homepage": "http://www.php-fig.org/" } ], - "description": "Mock Object library for PHPUnit", - "homepage": "https://github.com/sebastianbergmann/phpunit-mock-objects/", + "description": "Common interface for HTTP clients", + "homepage": "https://github.com/php-fig/http-client", "keywords": [ - "mock", - "xunit" + "http", + "http-client", + "psr", + "psr-18" ], - "abandoned": true, - "time": "2017-06-30T09:13:00+00:00" + "support": { + "source": "https://github.com/php-fig/http-client/tree/master" + }, + "time": "2020-06-29T06:28:15+00:00" }, { "name": "psr/http-message", @@ -1099,28 +1525,31 @@ "request", "response" ], + "support": { + "source": "https://github.com/php-fig/http-message/tree/master" + }, "time": "2016-08-06T14:39:51+00:00" }, { "name": "ralouphie/getallheaders", - "version": "2.0.5", + "version": "3.0.3", "source": { "type": "git", "url": "https://github.com/ralouphie/getallheaders.git", - "reference": "5601c8a83fbba7ef674a7369456d12f1e0d0eafa" + "reference": "120b605dfeb996808c31b6477290a714d356e822" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/ralouphie/getallheaders/zipball/5601c8a83fbba7ef674a7369456d12f1e0d0eafa", - "reference": "5601c8a83fbba7ef674a7369456d12f1e0d0eafa", + "url": "https://api.github.com/repos/ralouphie/getallheaders/zipball/120b605dfeb996808c31b6477290a714d356e822", + "reference": "120b605dfeb996808c31b6477290a714d356e822", "shasum": "" }, "require": { - "php": ">=5.3" + "php": ">=5.6" }, "require-dev": { - "phpunit/phpunit": "~3.7.0", - "satooshi/php-coveralls": ">=1.0" + "php-coveralls/php-coveralls": "^2.1", + "phpunit/phpunit": "^5 || ^6.5" }, "type": "library", "autoload": { @@ -1139,32 +1568,495 @@ } ], "description": "A polyfill for getallheaders.", - "time": "2016-02-11T07:05:27+00:00" + "support": { + "issues": "https://github.com/ralouphie/getallheaders/issues", + "source": "https://github.com/ralouphie/getallheaders/tree/develop" + }, + "time": "2019-03-08T08:55:37+00:00" }, { - "name": "sebastian/code-unit-reverse-lookup", - "version": "1.0.1", + "name": "roave/security-advisories", + "version": "dev-latest", "source": { "type": "git", - "url": "https://github.com/sebastianbergmann/code-unit-reverse-lookup.git", - "reference": "4419fcdb5eabb9caa61a27c7a1db532a6b55dd18" + "url": "https://github.com/Roave/SecurityAdvisories.git", + "reference": "593c4de369ca852cf3b86037f19435d47c136448" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/code-unit-reverse-lookup/zipball/4419fcdb5eabb9caa61a27c7a1db532a6b55dd18", - "reference": "4419fcdb5eabb9caa61a27c7a1db532a6b55dd18", + "url": "https://api.github.com/repos/Roave/SecurityAdvisories/zipball/593c4de369ca852cf3b86037f19435d47c136448", + "reference": "593c4de369ca852cf3b86037f19435d47c136448", + "shasum": "" + }, + "conflict": { + "3f/pygmentize": "<1.2", + "adodb/adodb-php": "<5.20.12", + "alterphp/easyadmin-extension-bundle": ">=1.2,<1.2.11|>=1.3,<1.3.1", + "amphp/artax": "<1.0.6|>=2,<2.0.6", + "amphp/http": "<1.0.1", + "amphp/http-client": ">=4,<4.4", + "api-platform/core": ">=2.2,<2.2.10|>=2.3,<2.3.6", + "asymmetricrypt/asymmetricrypt": ">=0,<9.9.99", + "aws/aws-sdk-php": ">=3,<3.2.1", + "bagisto/bagisto": "<0.1.5", + "barrelstrength/sprout-base-email": "<1.2.7", + "barrelstrength/sprout-forms": "<3.9", + "baserproject/basercms": ">=4,<=4.3.6|>=4.4,<4.4.1", + "bolt/bolt": "<3.7.1", + "bolt/core": "<4.1.13", + "brightlocal/phpwhois": "<=4.2.5", + "buddypress/buddypress": "<5.1.2", + "bugsnag/bugsnag-laravel": ">=2,<2.0.2", + "cakephp/cakephp": ">=1.3,<1.3.18|>=2,<2.4.99|>=2.5,<2.5.99|>=2.6,<2.6.12|>=2.7,<2.7.6|>=3,<3.5.18|>=3.6,<3.6.15|>=3.7,<3.7.7", + "cart2quote/module-quotation": ">=4.1.6,<=4.4.5|>=5,<5.4.4", + "cartalyst/sentry": "<=2.1.6", + "centreon/centreon": "<18.10.8|>=19,<19.4.5", + "cesnet/simplesamlphp-module-proxystatistics": "<3.1", + "codeigniter/framework": "<=3.0.6", + "composer/composer": "<=1-alpha.11", + "contao-components/mediaelement": ">=2.14.2,<2.21.1", + "contao/core": ">=2,<3.5.39", + "contao/core-bundle": ">=4,<4.4.52|>=4.5,<4.9.6|= 4.10.0", + "contao/listing-bundle": ">=4,<4.4.8", + "datadog/dd-trace": ">=0.30,<0.30.2", + "david-garcia/phpwhois": "<=4.3.1", + "derhansen/sf_event_mgt": "<4.3.1|>=5,<5.1.1", + "doctrine/annotations": ">=1,<1.2.7", + "doctrine/cache": ">=1,<1.3.2|>=1.4,<1.4.2", + "doctrine/common": ">=2,<2.4.3|>=2.5,<2.5.1", + "doctrine/dbal": ">=2,<2.0.8|>=2.1,<2.1.2", + "doctrine/doctrine-bundle": "<1.5.2", + "doctrine/doctrine-module": "<=0.7.1", + "doctrine/mongodb-odm": ">=1,<1.0.2", + "doctrine/mongodb-odm-bundle": ">=2,<3.0.1", + "doctrine/orm": ">=2,<2.4.8|>=2.5,<2.5.1|>=2.8.3,<2.8.4", + "dolibarr/dolibarr": "<11.0.4", + "dompdf/dompdf": ">=0.6,<0.6.2", + "drupal/core": ">=7,<7.74|>=8,<8.8.11|>=8.9,<8.9.9|>=9,<9.0.8", + "drupal/drupal": ">=7,<7.74|>=8,<8.8.11|>=8.9,<8.9.9|>=9,<9.0.8", + "endroid/qr-code-bundle": "<3.4.2", + "enshrined/svg-sanitize": "<0.13.1", + "erusev/parsedown": "<1.7.2", + "ezsystems/demobundle": ">=5.4,<5.4.6.1", + "ezsystems/ez-support-tools": ">=2.2,<2.2.3", + "ezsystems/ezdemo-ls-extension": ">=5.4,<5.4.2.1", + "ezsystems/ezfind-ls": ">=5.3,<5.3.6.1|>=5.4,<5.4.11.1|>=2017.12,<2017.12.0.1", + "ezsystems/ezplatform": ">=1.7,<1.7.9.1|>=1.13,<1.13.5.1|>=2.5,<2.5.4", + "ezsystems/ezplatform-admin-ui": ">=1.3,<1.3.5|>=1.4,<1.4.6", + "ezsystems/ezplatform-admin-ui-assets": ">=4,<4.2.1|>=5,<5.0.1|>=5.1,<5.1.1", + "ezsystems/ezplatform-kernel": "<=1.2.5|>=1.3,<=1.3.1", + "ezsystems/ezplatform-rest": ">=1.2,<=1.2.2|>=1.3,<=1.3.1", + "ezsystems/ezplatform-user": ">=1,<1.0.1", + "ezsystems/ezpublish-kernel": "<=6.13.8.1|>=7,<=7.5.15.1", + "ezsystems/ezpublish-legacy": ">=5.3,<5.3.12.6|>=5.4,<5.4.14.2|>=2011,<2017.12.7.3|>=2018.6,<2018.6.1.4|>=2018.9,<2018.9.1.3|>=2019.3,<2019.3.5.1", + "ezsystems/platform-ui-assets-bundle": ">=4.2,<4.2.3", + "ezsystems/repository-forms": ">=2.3,<2.3.2.1", + "ezyang/htmlpurifier": "<4.1.1", + "facade/ignition": "<1.16.14|>=2,<2.4.2|>=2.5,<2.5.2", + "firebase/php-jwt": "<2", + "flarum/sticky": ">=0.1-beta.14,<=0.1-beta.15", + "flarum/tags": "<=0.1-beta.13", + "fluidtypo3/vhs": "<5.1.1", + "fooman/tcpdf": "<6.2.22", + "fossar/tcpdf-parser": "<6.2.22", + "friendsofsymfony/oauth2-php": "<1.3", + "friendsofsymfony/rest-bundle": ">=1.2,<1.2.2", + "friendsofsymfony/user-bundle": ">=1.2,<1.3.5", + "friendsoftypo3/mediace": ">=7.6.2,<7.6.5", + "fuel/core": "<1.8.1", + "getgrav/grav": "<1.7.11", + "getkirby/cms": ">=3,<3.4.5", + "getkirby/panel": "<2.5.14", + "gos/web-socket-bundle": "<1.10.4|>=2,<2.6.1|>=3,<3.3", + "gree/jose": "<=2.2", + "gregwar/rst": "<1.0.3", + "guzzlehttp/guzzle": ">=4-rc.2,<4.2.4|>=5,<5.3.1|>=6,<6.2.1", + "illuminate/auth": ">=4,<4.0.99|>=4.1,<=4.1.31|>=4.2,<=4.2.22|>=5,<=5.0.35|>=5.1,<=5.1.46|>=5.2,<=5.2.45|>=5.3,<=5.3.31|>=5.4,<=5.4.36|>=5.5,<5.5.10", + "illuminate/cookie": ">=4,<=4.0.11|>=4.1,<=4.1.99999|>=4.2,<=4.2.99999|>=5,<=5.0.99999|>=5.1,<=5.1.99999|>=5.2,<=5.2.99999|>=5.3,<=5.3.99999|>=5.4,<=5.4.99999|>=5.5,<=5.5.49|>=5.6,<=5.6.99999|>=5.7,<=5.7.99999|>=5.8,<=5.8.99999|>=6,<6.18.31|>=7,<7.22.4", + "illuminate/database": "<6.20.14|>=7,<7.30.4|>=8,<8.24", + "illuminate/encryption": ">=4,<=4.0.11|>=4.1,<=4.1.31|>=4.2,<=4.2.22|>=5,<=5.0.35|>=5.1,<=5.1.46|>=5.2,<=5.2.45|>=5.3,<=5.3.31|>=5.4,<=5.4.36|>=5.5,<5.5.40|>=5.6,<5.6.15", + "illuminate/view": ">=7,<7.1.2", + "impresscms/impresscms": "<=1.4.2", + "ivankristianto/phpwhois": "<=4.3", + "james-heinrich/getid3": "<1.9.9", + "joomla/archive": "<1.1.10", + "joomla/session": "<1.3.1", + "jsmitty12/phpwhois": "<5.1", + "kazist/phpwhois": "<=4.2.6", + "kitodo/presentation": "<3.1.2", + "kreait/firebase-php": ">=3.2,<3.8.1", + "la-haute-societe/tcpdf": "<6.2.22", + "laravel/framework": "<6.20.14|>=7,<7.30.4|>=8,<8.24", + "laravel/socialite": ">=1,<1.0.99|>=2,<2.0.10", + "league/commonmark": "<0.18.3", + "librenms/librenms": "<1.53", + "livewire/livewire": ">2.2.4,<2.2.6", + "magento/community-edition": ">=2,<2.2.10|>=2.3,<2.3.3", + "magento/magento1ce": "<1.9.4.3", + "magento/magento1ee": ">=1,<1.14.4.3", + "magento/product-community-edition": ">=2,<2.2.10|>=2.3,<2.3.2-p.2", + "marcwillmann/turn": "<0.3.3", + "mautic/core": "<3.3.2|= 2.13.1", + "mediawiki/core": ">=1.27,<1.27.6|>=1.29,<1.29.3|>=1.30,<1.30.2|>=1.31,<1.31.9|>=1.32,<1.32.6|>=1.32.99,<1.33.3|>=1.33.99,<1.34.3|>=1.34.99,<1.35", + "mittwald/typo3_forum": "<1.2.1", + "monolog/monolog": ">=1.8,<1.12", + "moodle/moodle": "<3.5.17|>=3.7,<3.7.9|>=3.8,<3.8.8|>=3.9,<3.9.5|>=3.10,<3.10.2", + "namshi/jose": "<2.2", + "neos/flow": ">=1,<1.0.4|>=1.1,<1.1.1|>=2,<2.0.1|>=2.3,<2.3.16|>=3,<3.0.12|>=3.1,<3.1.10|>=3.2,<3.2.13|>=3.3,<3.3.13|>=4,<4.0.6", + "neos/neos": ">=1.1,<1.1.3|>=1.2,<1.2.13|>=2,<2.0.4|>=2.3,<2.9.99|>=3,<3.0.20|>=3.1,<3.1.18|>=3.2,<3.2.14|>=3.3,<3.3.23|>=4,<4.0.17|>=4.1,<4.1.16|>=4.2,<4.2.12|>=4.3,<4.3.3", + "neos/swiftmailer": ">=4.1,<4.1.99|>=5.4,<5.4.5", + "nette/application": ">=2,<2.0.19|>=2.1,<2.1.13|>=2.2,<2.2.10|>=2.3,<2.3.14|>=2.4,<2.4.16|>=3,<3.0.6", + "nette/nette": ">=2,<2.0.19|>=2.1,<2.1.13", + "nystudio107/craft-seomatic": "<3.3", + "nzo/url-encryptor-bundle": ">=4,<4.3.2|>=5,<5.0.1", + "october/backend": "<1.1.2", + "october/cms": "= 1.0.469|>=1.0.319,<1.0.469", + "october/october": ">=1.0.319,<1.0.466", + "october/rain": "<1.0.472|>=1.1,<1.1.2", + "onelogin/php-saml": "<2.10.4", + "oneup/uploader-bundle": "<1.9.3|>=2,<2.1.5", + "openid/php-openid": "<2.3", + "openmage/magento-lts": "<19.4.8|>=20,<20.0.4", + "orchid/platform": ">=9,<9.4.4", + "oro/crm": ">=1.7,<1.7.4", + "oro/platform": ">=1.7,<1.7.4", + "padraic/humbug_get_contents": "<1.1.2", + "pagarme/pagarme-php": ">=0,<3", + "paragonie/random_compat": "<2", + "passbolt/passbolt_api": "<2.11", + "paypal/merchant-sdk-php": "<3.12", + "pear/archive_tar": "<1.4.12", + "personnummer/personnummer": "<3.0.2", + "phpfastcache/phpfastcache": ">=5,<5.0.13", + "phpmailer/phpmailer": "<6.1.6", + "phpmussel/phpmussel": ">=1,<1.6", + "phpmyadmin/phpmyadmin": "<4.9.6|>=5,<5.0.3", + "phpoffice/phpexcel": "<1.8.2", + "phpoffice/phpspreadsheet": "<1.16", + "phpseclib/phpseclib": "<2.0.31|>=3,<3.0.7", + "phpunit/phpunit": ">=4.8.19,<4.8.28|>=5.0.10,<5.6.3", + "phpwhois/phpwhois": "<=4.2.5", + "phpxmlrpc/extras": "<0.6.1", + "pimcore/pimcore": "<6.8.8", + "pocketmine/pocketmine-mp": "<3.15.4", + "pressbooks/pressbooks": "<5.18", + "prestashop/autoupgrade": ">=4,<4.10.1", + "prestashop/contactform": ">1.0.1,<4.3", + "prestashop/gamification": "<2.3.2", + "prestashop/productcomments": ">=4,<4.2.1", + "prestashop/ps_emailsubscription": "<2.6.1", + "prestashop/ps_facetedsearch": "<3.4.1", + "privatebin/privatebin": "<1.2.2|>=1.3,<1.3.2", + "propel/propel": ">=2-alpha.1,<=2-alpha.7", + "propel/propel1": ">=1,<=1.7.1", + "pterodactyl/panel": "<0.7.19|>=1-rc.0,<=1-rc.6", + "pusher/pusher-php-server": "<2.2.1", + "pwweb/laravel-core": "<=0.3.6-beta", + "rainlab/debugbar-plugin": "<3.1", + "robrichards/xmlseclibs": "<3.0.4", + "sabberworm/php-css-parser": ">=1,<1.0.1|>=2,<2.0.1|>=3,<3.0.1|>=4,<4.0.1|>=5,<5.0.9|>=5.1,<5.1.3|>=5.2,<5.2.1|>=6,<6.0.2|>=7,<7.0.4|>=8,<8.0.1|>=8.1,<8.1.1|>=8.2,<8.2.1|>=8.3,<8.3.1", + "sabre/dav": ">=1.6,<1.6.99|>=1.7,<1.7.11|>=1.8,<1.8.9", + "scheb/two-factor-bundle": ">=0,<3.26|>=4,<4.11", + "sensiolabs/connect": "<4.2.3", + "serluck/phpwhois": "<=4.2.6", + "shopware/core": "<=6.3.5.2", + "shopware/platform": "<=6.3.5.2", + "shopware/production": "<=6.3.5.2", + "shopware/shopware": "<5.6.9", + "silverstripe/admin": ">=1.0.3,<1.0.4|>=1.1,<1.1.1", + "silverstripe/assets": ">=1,<1.4.7|>=1.5,<1.5.2", + "silverstripe/cms": "<4.3.6|>=4.4,<4.4.4", + "silverstripe/comments": ">=1.3,<1.9.99|>=2,<2.9.99|>=3,<3.1.1", + "silverstripe/forum": "<=0.6.1|>=0.7,<=0.7.3", + "silverstripe/framework": "<4.4.7|>=4.5,<4.5.4", + "silverstripe/graphql": ">=2,<2.0.5|>=3,<3.1.2|>=3.2,<3.2.4", + "silverstripe/registry": ">=2.1,<2.1.2|>=2.2,<2.2.1", + "silverstripe/restfulserver": ">=1,<1.0.9|>=2,<2.0.4", + "silverstripe/subsites": ">=2,<2.1.1", + "silverstripe/taxonomy": ">=1.3,<1.3.1|>=2,<2.0.1", + "silverstripe/userforms": "<3", + "simple-updates/phpwhois": "<=1", + "simplesamlphp/saml2": "<1.10.6|>=2,<2.3.8|>=3,<3.1.4", + "simplesamlphp/simplesamlphp": "<1.18.6", + "simplesamlphp/simplesamlphp-module-infocard": "<1.0.1", + "simplito/elliptic-php": "<1.0.6", + "slim/slim": "<2.6", + "smarty/smarty": "<3.1.39", + "socalnick/scn-social-auth": "<1.15.2", + "socialiteproviders/steam": "<1.1", + "spoonity/tcpdf": "<6.2.22", + "squizlabs/php_codesniffer": ">=1,<2.8.1|>=3,<3.0.1", + "ssddanbrown/bookstack": "<0.29.2", + "stormpath/sdk": ">=0,<9.9.99", + "studio-42/elfinder": "<2.1.49", + "sulu/sulu": "<1.6.34|>=2,<2.0.10|>=2.1,<2.1.1", + "swiftmailer/swiftmailer": ">=4,<5.4.5", + "sylius/admin-bundle": ">=1,<1.0.17|>=1.1,<1.1.9|>=1.2,<1.2.2", + "sylius/grid": ">=1,<1.1.19|>=1.2,<1.2.18|>=1.3,<1.3.13|>=1.4,<1.4.5|>=1.5,<1.5.1", + "sylius/grid-bundle": ">=1,<1.1.19|>=1.2,<1.2.18|>=1.3,<1.3.13|>=1.4,<1.4.5|>=1.5,<1.5.1", + "sylius/resource-bundle": "<1.3.14|>=1.4,<1.4.7|>=1.5,<1.5.2|>=1.6,<1.6.4", + "sylius/sylius": "<1.6.9|>=1.7,<1.7.9|>=1.8,<1.8.3", + "symbiote/silverstripe-multivaluefield": ">=3,<3.0.99", + "symbiote/silverstripe-queuedjobs": ">=3,<3.0.2|>=3.1,<3.1.4|>=4,<4.0.7|>=4.1,<4.1.2|>=4.2,<4.2.4|>=4.3,<4.3.3|>=4.4,<4.4.3|>=4.5,<4.5.1|>=4.6,<4.6.4", + "symbiote/silverstripe-versionedfiles": "<=2.0.3", + "symfony/cache": ">=3.1,<3.4.35|>=4,<4.2.12|>=4.3,<4.3.8", + "symfony/dependency-injection": ">=2,<2.0.17|>=2.7,<2.7.51|>=2.8,<2.8.50|>=3,<3.4.26|>=4,<4.1.12|>=4.2,<4.2.7", + "symfony/error-handler": ">=4.4,<4.4.4|>=5,<5.0.4", + "symfony/form": ">=2.3,<2.3.35|>=2.4,<2.6.12|>=2.7,<2.7.50|>=2.8,<2.8.49|>=3,<3.4.20|>=4,<4.0.15|>=4.1,<4.1.9|>=4.2,<4.2.1", + "symfony/framework-bundle": ">=2,<2.3.18|>=2.4,<2.4.8|>=2.5,<2.5.2|>=2.7,<2.7.51|>=2.8,<2.8.50|>=3,<3.4.26|>=4,<4.1.12|>=4.2,<4.2.7", + "symfony/http-foundation": ">=2,<2.8.52|>=3,<3.4.35|>=4,<4.2.12|>=4.3,<4.3.8|>=4.4,<4.4.7|>=5,<5.0.7", + "symfony/http-kernel": ">=2,<2.8.52|>=3,<3.4.35|>=4,<4.2.12|>=4.3,<4.4.13|>=5,<5.1.5", + "symfony/intl": ">=2.7,<2.7.38|>=2.8,<2.8.31|>=3,<3.2.14|>=3.3,<3.3.13", + "symfony/mime": ">=4.3,<4.3.8", + "symfony/phpunit-bridge": ">=2.8,<2.8.50|>=3,<3.4.26|>=4,<4.1.12|>=4.2,<4.2.7", + "symfony/polyfill": ">=1,<1.10", + "symfony/polyfill-php55": ">=1,<1.10", + "symfony/proxy-manager-bridge": ">=2.7,<2.7.51|>=2.8,<2.8.50|>=3,<3.4.26|>=4,<4.1.12|>=4.2,<4.2.7", + "symfony/routing": ">=2,<2.0.19", + "symfony/security": ">=2,<2.7.51|>=2.8,<2.8.50|>=3,<3.4.26|>=4,<4.1.12|>=4.2,<4.2.7|>=4.4,<4.4.7|>=5,<5.0.7", + "symfony/security-bundle": ">=2,<2.7.48|>=2.8,<2.8.41|>=3,<3.3.17|>=3.4,<3.4.11|>=4,<4.0.11", + "symfony/security-core": ">=2.4,<2.6.13|>=2.7,<2.7.9|>=2.7.30,<2.7.32|>=2.8,<2.8.37|>=3,<3.3.17|>=3.4,<3.4.7|>=4,<4.0.7", + "symfony/security-csrf": ">=2.4,<2.7.48|>=2.8,<2.8.41|>=3,<3.3.17|>=3.4,<3.4.11|>=4,<4.0.11", + "symfony/security-guard": ">=2.8,<2.8.41|>=3,<3.3.17|>=3.4,<3.4.11|>=4,<4.0.11", + "symfony/security-http": ">=2.3,<2.3.41|>=2.4,<2.7.51|>=2.8,<2.8.50|>=3,<3.4.26|>=4,<4.2.12|>=4.3,<4.3.8|>=4.4,<4.4.7|>=5,<5.0.7", + "symfony/serializer": ">=2,<2.0.11", + "symfony/symfony": ">=2,<2.8.52|>=3,<3.4.35|>=4,<4.2.12|>=4.3,<4.4.13|>=5,<5.1.5", + "symfony/translation": ">=2,<2.0.17", + "symfony/validator": ">=2,<2.0.24|>=2.1,<2.1.12|>=2.2,<2.2.5|>=2.3,<2.3.3", + "symfony/var-exporter": ">=4.2,<4.2.12|>=4.3,<4.3.8", + "symfony/web-profiler-bundle": ">=2,<2.3.19|>=2.4,<2.4.9|>=2.5,<2.5.4", + "symfony/yaml": ">=2,<2.0.22|>=2.1,<2.1.7", + "t3g/svg-sanitizer": "<1.0.3", + "tecnickcom/tcpdf": "<6.2.22", + "thelia/backoffice-default-template": ">=2.1,<2.1.2", + "thelia/thelia": ">=2.1-beta.1,<2.1.3", + "theonedemon/phpwhois": "<=4.2.5", + "titon/framework": ">=0,<9.9.99", + "truckersmp/phpwhois": "<=4.3.1", + "twig/twig": "<1.38|>=2,<2.7", + "typo3/cms": ">=6.2,<6.2.30|>=7,<7.6.32|>=8,<8.7.38|>=9,<9.5.25|>=10,<10.4.14|>=11,<11.1.1", + "typo3/cms-backend": ">=7,<=7.6.50|>=8,<=8.7.39|>=9,<=9.5.24|>=10,<=10.4.13|>=11,<=11.1", + "typo3/cms-core": ">=6.2,<=6.2.56|>=7,<=7.6.50|>=8,<=8.7.39|>=9,<9.5.25|>=10,<10.4.14|>=11,<11.1.1", + "typo3/cms-form": ">=8,<=8.7.39|>=9,<=9.5.24|>=10,<=10.4.13|>=11,<=11.1", + "typo3/flow": ">=1,<1.0.4|>=1.1,<1.1.1|>=2,<2.0.1|>=2.3,<2.3.16|>=3,<3.0.12|>=3.1,<3.1.10|>=3.2,<3.2.13|>=3.3,<3.3.13|>=4,<4.0.6", + "typo3/neos": ">=1.1,<1.1.3|>=1.2,<1.2.13|>=2,<2.0.4|>=2.3,<2.3.99|>=3,<3.0.20|>=3.1,<3.1.18|>=3.2,<3.2.14|>=3.3,<3.3.23|>=4,<4.0.17|>=4.1,<4.1.16|>=4.2,<4.2.12|>=4.3,<4.3.3", + "typo3/phar-stream-wrapper": ">=1,<2.1.1|>=3,<3.1.1", + "typo3/swiftmailer": ">=4.1,<4.1.99|>=5.4,<5.4.5", + "typo3fluid/fluid": ">=2,<2.0.8|>=2.1,<2.1.7|>=2.2,<2.2.4|>=2.3,<2.3.7|>=2.4,<2.4.4|>=2.5,<2.5.11|>=2.6,<2.6.10", + "ua-parser/uap-php": "<3.8", + "usmanhalalit/pixie": "<1.0.3|>=2,<2.0.2", + "verot/class.upload.php": "<=1.0.3|>=2,<=2.0.4", + "vrana/adminer": "<4.7.9", + "wallabag/tcpdf": "<6.2.22", + "wikimedia/parsoid": "<0.12.2", + "willdurand/js-translation-bundle": "<2.1.1", + "yii2mod/yii2-cms": "<1.9.2", + "yiisoft/yii": ">=1.1.14,<1.1.15", + "yiisoft/yii2": "<2.0.38", + "yiisoft/yii2-bootstrap": "<2.0.4", + "yiisoft/yii2-dev": "<2.0.15", + "yiisoft/yii2-elasticsearch": "<2.0.5", + "yiisoft/yii2-gii": "<2.0.4", + "yiisoft/yii2-jui": "<2.0.4", + "yiisoft/yii2-redis": "<2.0.8", + "yourls/yourls": "<1.7.4", + "zendframework/zend-cache": ">=2.4,<2.4.8|>=2.5,<2.5.3", + "zendframework/zend-captcha": ">=2,<2.4.9|>=2.5,<2.5.2", + "zendframework/zend-crypt": ">=2,<2.4.9|>=2.5,<2.5.2", + "zendframework/zend-db": ">=2,<2.0.99|>=2.1,<2.1.99|>=2.2,<2.2.10|>=2.3,<2.3.5", + "zendframework/zend-developer-tools": ">=1.2.2,<1.2.3", + "zendframework/zend-diactoros": ">=1,<1.8.4", + "zendframework/zend-feed": ">=1,<2.10.3", + "zendframework/zend-form": ">=2,<2.2.7|>=2.3,<2.3.1", + "zendframework/zend-http": ">=1,<2.8.1", + "zendframework/zend-json": ">=2.1,<2.1.6|>=2.2,<2.2.6", + "zendframework/zend-ldap": ">=2,<2.0.99|>=2.1,<2.1.99|>=2.2,<2.2.8|>=2.3,<2.3.3", + "zendframework/zend-mail": ">=2,<2.4.11|>=2.5,<2.7.2", + "zendframework/zend-navigation": ">=2,<2.2.7|>=2.3,<2.3.1", + "zendframework/zend-session": ">=2,<2.0.99|>=2.1,<2.1.99|>=2.2,<2.2.9|>=2.3,<2.3.4", + "zendframework/zend-validator": ">=2.3,<2.3.6", + "zendframework/zend-view": ">=2,<2.2.7|>=2.3,<2.3.1", + "zendframework/zend-xmlrpc": ">=2.1,<2.1.6|>=2.2,<2.2.6", + "zendframework/zendframework": "<2.5.1", + "zendframework/zendframework1": "<1.12.20", + "zendframework/zendopenid": ">=2,<2.0.2", + "zendframework/zendxml": ">=1,<1.0.1", + "zetacomponents/mail": "<1.8.2", + "zf-commons/zfc-user": "<1.2.2", + "zfcampus/zf-apigility-doctrine": ">=1,<1.0.3", + "zfr/zfr-oauth2-server-module": "<0.1.2" + }, + "default-branch": true, + "type": "metapackage", + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Marco Pivetta", + "email": "ocramius@gmail.com", + "role": "maintainer" + }, + { + "name": "Ilya Tribusean", + "email": "slash3b@gmail.com", + "role": "maintainer" + } + ], + "description": "Prevents installation of composer packages with known security vulnerabilities: no API, simply require it", + "support": { + "issues": "https://github.com/Roave/SecurityAdvisories/issues", + "source": "https://github.com/Roave/SecurityAdvisories/tree/latest" + }, + "funding": [ + { + "url": "https://github.com/Ocramius", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/roave/security-advisories", + "type": "tidelift" + } + ], + "time": "2021-04-16T20:01:44+00:00" + }, + { + "name": "sebastian/cli-parser", + "version": "1.0.1", + "source": { + "type": "git", + "url": "https://github.com/sebastianbergmann/cli-parser.git", + "reference": "442e7c7e687e42adc03470c7b668bc4b2402c0b2" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/sebastianbergmann/cli-parser/zipball/442e7c7e687e42adc03470c7b668bc4b2402c0b2", + "reference": "442e7c7e687e42adc03470c7b668bc4b2402c0b2", "shasum": "" }, "require": { - "php": "^5.6 || ^7.0" + "php": ">=7.3" }, "require-dev": { - "phpunit/phpunit": "^5.7 || ^6.0" + "phpunit/phpunit": "^9.3" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "1.0.x-dev" + "dev-master": "1.0-dev" + } + }, + "autoload": { + "classmap": [ + "src/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "BSD-3-Clause" + ], + "authors": [ + { + "name": "Sebastian Bergmann", + "email": "sebastian@phpunit.de", + "role": "lead" + } + ], + "description": "Library for parsing CLI options", + "homepage": "https://github.com/sebastianbergmann/cli-parser", + "support": { + "issues": "https://github.com/sebastianbergmann/cli-parser/issues", + "source": "https://github.com/sebastianbergmann/cli-parser/tree/1.0.1" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } + ], + "time": "2020-09-28T06:08:49+00:00" + }, + { + "name": "sebastian/code-unit", + "version": "1.0.8", + "source": { + "type": "git", + "url": "https://github.com/sebastianbergmann/code-unit.git", + "reference": "1fc9f64c0927627ef78ba436c9b17d967e68e120" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/sebastianbergmann/code-unit/zipball/1fc9f64c0927627ef78ba436c9b17d967e68e120", + "reference": "1fc9f64c0927627ef78ba436c9b17d967e68e120", + "shasum": "" + }, + "require": { + "php": ">=7.3" + }, + "require-dev": { + "phpunit/phpunit": "^9.3" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "1.0-dev" + } + }, + "autoload": { + "classmap": [ + "src/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "BSD-3-Clause" + ], + "authors": [ + { + "name": "Sebastian Bergmann", + "email": "sebastian@phpunit.de", + "role": "lead" + } + ], + "description": "Collection of value objects that represent the PHP code units", + "homepage": "https://github.com/sebastianbergmann/code-unit", + "support": { + "issues": "https://github.com/sebastianbergmann/code-unit/issues", + "source": "https://github.com/sebastianbergmann/code-unit/tree/1.0.8" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } + ], + "time": "2020-10-26T13:08:54+00:00" + }, + { + "name": "sebastian/code-unit-reverse-lookup", + "version": "2.0.3", + "source": { + "type": "git", + "url": "https://github.com/sebastianbergmann/code-unit-reverse-lookup.git", + "reference": "ac91f01ccec49fb77bdc6fd1e548bc70f7faa3e5" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/sebastianbergmann/code-unit-reverse-lookup/zipball/ac91f01ccec49fb77bdc6fd1e548bc70f7faa3e5", + "reference": "ac91f01ccec49fb77bdc6fd1e548bc70f7faa3e5", + "shasum": "" + }, + "require": { + "php": ">=7.3" + }, + "require-dev": { + "phpunit/phpunit": "^9.3" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "2.0-dev" } }, "autoload": { @@ -1184,34 +2076,44 @@ ], "description": "Looks up which function or method a line of code belongs to", "homepage": "https://github.com/sebastianbergmann/code-unit-reverse-lookup/", - "time": "2017-03-04T06:30:41+00:00" + "support": { + "issues": "https://github.com/sebastianbergmann/code-unit-reverse-lookup/issues", + "source": "https://github.com/sebastianbergmann/code-unit-reverse-lookup/tree/2.0.3" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } + ], + "time": "2020-09-28T05:30:19+00:00" }, { "name": "sebastian/comparator", - "version": "1.2.4", + "version": "4.0.6", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/comparator.git", - "reference": "2b7424b55f5047b47ac6e5ccb20b2aea4011d9be" + "reference": "55f4261989e546dc112258c7a75935a81a7ce382" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/comparator/zipball/2b7424b55f5047b47ac6e5ccb20b2aea4011d9be", - "reference": "2b7424b55f5047b47ac6e5ccb20b2aea4011d9be", + "url": "https://api.github.com/repos/sebastianbergmann/comparator/zipball/55f4261989e546dc112258c7a75935a81a7ce382", + "reference": "55f4261989e546dc112258c7a75935a81a7ce382", "shasum": "" }, "require": { - "php": ">=5.3.3", - "sebastian/diff": "~1.2", - "sebastian/exporter": "~1.2 || ~2.0" + "php": ">=7.3", + "sebastian/diff": "^4.0", + "sebastian/exporter": "^4.0" }, "require-dev": { - "phpunit/phpunit": "~4.4" + "phpunit/phpunit": "^9.3" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "1.2.x-dev" + "dev-master": "4.0-dev" } }, "autoload": { @@ -1224,6 +2126,10 @@ "BSD-3-Clause" ], "authors": [ + { + "name": "Sebastian Bergmann", + "email": "sebastian@phpunit.de" + }, { "name": "Jeff Welch", "email": "whatthejeff@gmail.com" @@ -1235,45 +2141,52 @@ { "name": "Bernhard Schussek", "email": "bschussek@2bepublished.at" - }, - { - "name": "Sebastian Bergmann", - "email": "sebastian@phpunit.de" } ], "description": "Provides the functionality to compare PHP values for equality", - "homepage": "http://www.github.com/sebastianbergmann/comparator", + "homepage": "https://github.com/sebastianbergmann/comparator", "keywords": [ "comparator", "compare", "equality" ], - "time": "2017-01-29T09:50:25+00:00" + "support": { + "issues": "https://github.com/sebastianbergmann/comparator/issues", + "source": "https://github.com/sebastianbergmann/comparator/tree/4.0.6" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } + ], + "time": "2020-10-26T15:49:45+00:00" }, { - "name": "sebastian/diff", - "version": "1.4.3", + "name": "sebastian/complexity", + "version": "2.0.2", "source": { "type": "git", - "url": "https://github.com/sebastianbergmann/diff.git", - "reference": "7f066a26a962dbe58ddea9f72a4e82874a3975a4" + "url": "https://github.com/sebastianbergmann/complexity.git", + "reference": "739b35e53379900cc9ac327b2147867b8b6efd88" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/diff/zipball/7f066a26a962dbe58ddea9f72a4e82874a3975a4", - "reference": "7f066a26a962dbe58ddea9f72a4e82874a3975a4", + "url": "https://api.github.com/repos/sebastianbergmann/complexity/zipball/739b35e53379900cc9ac327b2147867b8b6efd88", + "reference": "739b35e53379900cc9ac327b2147867b8b6efd88", "shasum": "" }, "require": { - "php": "^5.3.3 || ^7.0" + "nikic/php-parser": "^4.7", + "php": ">=7.3" }, "require-dev": { - "phpunit/phpunit": "^4.8.35 || ^5.7 || ^6.0" + "phpunit/phpunit": "^9.3" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "1.4-dev" + "dev-master": "2.0-dev" } }, "autoload": { @@ -1287,45 +2200,118 @@ ], "authors": [ { - "name": "Kore Nordmann", - "email": "mail@kore-nordmann.de" - }, + "name": "Sebastian Bergmann", + "email": "sebastian@phpunit.de", + "role": "lead" + } + ], + "description": "Library for calculating the complexity of PHP code units", + "homepage": "https://github.com/sebastianbergmann/complexity", + "support": { + "issues": "https://github.com/sebastianbergmann/complexity/issues", + "source": "https://github.com/sebastianbergmann/complexity/tree/2.0.2" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } + ], + "time": "2020-10-26T15:52:27+00:00" + }, + { + "name": "sebastian/diff", + "version": "4.0.4", + "source": { + "type": "git", + "url": "https://github.com/sebastianbergmann/diff.git", + "reference": "3461e3fccc7cfdfc2720be910d3bd73c69be590d" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/sebastianbergmann/diff/zipball/3461e3fccc7cfdfc2720be910d3bd73c69be590d", + "reference": "3461e3fccc7cfdfc2720be910d3bd73c69be590d", + "shasum": "" + }, + "require": { + "php": ">=7.3" + }, + "require-dev": { + "phpunit/phpunit": "^9.3", + "symfony/process": "^4.2 || ^5" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "4.0-dev" + } + }, + "autoload": { + "classmap": [ + "src/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "BSD-3-Clause" + ], + "authors": [ { "name": "Sebastian Bergmann", "email": "sebastian@phpunit.de" + }, + { + "name": "Kore Nordmann", + "email": "mail@kore-nordmann.de" } ], "description": "Diff implementation", "homepage": "https://github.com/sebastianbergmann/diff", "keywords": [ - "diff" + "diff", + "udiff", + "unidiff", + "unified diff" ], - "time": "2017-05-22T07:24:03+00:00" + "support": { + "issues": "https://github.com/sebastianbergmann/diff/issues", + "source": "https://github.com/sebastianbergmann/diff/tree/4.0.4" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } + ], + "time": "2020-10-26T13:10:38+00:00" }, { "name": "sebastian/environment", - "version": "2.0.0", + "version": "5.1.3", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/environment.git", - "reference": "5795ffe5dc5b02460c3e34222fee8cbe245d8fac" + "reference": "388b6ced16caa751030f6a69e588299fa09200ac" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/environment/zipball/5795ffe5dc5b02460c3e34222fee8cbe245d8fac", - "reference": "5795ffe5dc5b02460c3e34222fee8cbe245d8fac", + "url": "https://api.github.com/repos/sebastianbergmann/environment/zipball/388b6ced16caa751030f6a69e588299fa09200ac", + "reference": "388b6ced16caa751030f6a69e588299fa09200ac", "shasum": "" }, "require": { - "php": "^5.6 || ^7.0" + "php": ">=7.3" }, "require-dev": { - "phpunit/phpunit": "^5.0" + "phpunit/phpunit": "^9.3" + }, + "suggest": { + "ext-posix": "*" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "2.0.x-dev" + "dev-master": "5.1-dev" } }, "autoload": { @@ -1350,34 +2336,44 @@ "environment", "hhvm" ], - "time": "2016-11-26T07:53:53+00:00" + "support": { + "issues": "https://github.com/sebastianbergmann/environment/issues", + "source": "https://github.com/sebastianbergmann/environment/tree/5.1.3" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } + ], + "time": "2020-09-28T05:52:38+00:00" }, { "name": "sebastian/exporter", - "version": "2.0.0", + "version": "4.0.3", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/exporter.git", - "reference": "ce474bdd1a34744d7ac5d6aad3a46d48d9bac4c4" + "reference": "d89cc98761b8cb5a1a235a6b703ae50d34080e65" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/exporter/zipball/ce474bdd1a34744d7ac5d6aad3a46d48d9bac4c4", - "reference": "ce474bdd1a34744d7ac5d6aad3a46d48d9bac4c4", + "url": "https://api.github.com/repos/sebastianbergmann/exporter/zipball/d89cc98761b8cb5a1a235a6b703ae50d34080e65", + "reference": "d89cc98761b8cb5a1a235a6b703ae50d34080e65", "shasum": "" }, "require": { - "php": ">=5.3.3", - "sebastian/recursion-context": "~2.0" + "php": ">=7.3", + "sebastian/recursion-context": "^4.0" }, "require-dev": { "ext-mbstring": "*", - "phpunit/phpunit": "~4.4" + "phpunit/phpunit": "^9.3" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "2.0.x-dev" + "dev-master": "4.0-dev" } }, "autoload": { @@ -1390,6 +2386,10 @@ "BSD-3-Clause" ], "authors": [ + { + "name": "Sebastian Bergmann", + "email": "sebastian@phpunit.de" + }, { "name": "Jeff Welch", "email": "whatthejeff@gmail.com" @@ -1398,17 +2398,13 @@ "name": "Volker Dusch", "email": "github@wallbash.com" }, - { - "name": "Bernhard Schussek", - "email": "bschussek@2bepublished.at" - }, - { - "name": "Sebastian Bergmann", - "email": "sebastian@phpunit.de" - }, { "name": "Adam Harvey", "email": "aharvey@php.net" + }, + { + "name": "Bernhard Schussek", + "email": "bschussek@gmail.com" } ], "description": "Provides the functionality to export PHP variables for visualization", @@ -1417,27 +2413,40 @@ "export", "exporter" ], - "time": "2016-11-19T08:54:04+00:00" + "support": { + "issues": "https://github.com/sebastianbergmann/exporter/issues", + "source": "https://github.com/sebastianbergmann/exporter/tree/4.0.3" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } + ], + "time": "2020-09-28T05:24:23+00:00" }, { "name": "sebastian/global-state", - "version": "1.1.1", + "version": "5.0.2", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/global-state.git", - "reference": "bc37d50fea7d017d3d340f230811c9f1d7280af4" + "reference": "a90ccbddffa067b51f574dea6eb25d5680839455" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/global-state/zipball/bc37d50fea7d017d3d340f230811c9f1d7280af4", - "reference": "bc37d50fea7d017d3d340f230811c9f1d7280af4", + "url": "https://api.github.com/repos/sebastianbergmann/global-state/zipball/a90ccbddffa067b51f574dea6eb25d5680839455", + "reference": "a90ccbddffa067b51f574dea6eb25d5680839455", "shasum": "" }, "require": { - "php": ">=5.3.3" + "php": ">=7.3", + "sebastian/object-reflector": "^2.0", + "sebastian/recursion-context": "^4.0" }, "require-dev": { - "phpunit/phpunit": "~4.2" + "ext-dom": "*", + "phpunit/phpunit": "^9.3" }, "suggest": { "ext-uopz": "*" @@ -1445,7 +2454,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-master": "1.0-dev" + "dev-master": "5.0-dev" } }, "autoload": { @@ -1468,33 +2477,101 @@ "keywords": [ "global state" ], - "time": "2015-10-12T03:26:01+00:00" + "support": { + "issues": "https://github.com/sebastianbergmann/global-state/issues", + "source": "https://github.com/sebastianbergmann/global-state/tree/5.0.2" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } + ], + "time": "2020-10-26T15:55:19+00:00" }, { - "name": "sebastian/object-enumerator", - "version": "2.0.1", + "name": "sebastian/lines-of-code", + "version": "1.0.3", "source": { "type": "git", - "url": "https://github.com/sebastianbergmann/object-enumerator.git", - "reference": "1311872ac850040a79c3c058bea3e22d0f09cbb7" + "url": "https://github.com/sebastianbergmann/lines-of-code.git", + "reference": "c1c2e997aa3146983ed888ad08b15470a2e22ecc" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/object-enumerator/zipball/1311872ac850040a79c3c058bea3e22d0f09cbb7", - "reference": "1311872ac850040a79c3c058bea3e22d0f09cbb7", + "url": "https://api.github.com/repos/sebastianbergmann/lines-of-code/zipball/c1c2e997aa3146983ed888ad08b15470a2e22ecc", + "reference": "c1c2e997aa3146983ed888ad08b15470a2e22ecc", "shasum": "" }, "require": { - "php": ">=5.6", - "sebastian/recursion-context": "~2.0" + "nikic/php-parser": "^4.6", + "php": ">=7.3" }, "require-dev": { - "phpunit/phpunit": "~5" + "phpunit/phpunit": "^9.3" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "2.0.x-dev" + "dev-master": "1.0-dev" + } + }, + "autoload": { + "classmap": [ + "src/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "BSD-3-Clause" + ], + "authors": [ + { + "name": "Sebastian Bergmann", + "email": "sebastian@phpunit.de", + "role": "lead" + } + ], + "description": "Library for counting the lines of code in PHP source code", + "homepage": "https://github.com/sebastianbergmann/lines-of-code", + "support": { + "issues": "https://github.com/sebastianbergmann/lines-of-code/issues", + "source": "https://github.com/sebastianbergmann/lines-of-code/tree/1.0.3" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } + ], + "time": "2020-11-28T06:42:11+00:00" + }, + { + "name": "sebastian/object-enumerator", + "version": "4.0.4", + "source": { + "type": "git", + "url": "https://github.com/sebastianbergmann/object-enumerator.git", + "reference": "5c9eeac41b290a3712d88851518825ad78f45c71" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/sebastianbergmann/object-enumerator/zipball/5c9eeac41b290a3712d88851518825ad78f45c71", + "reference": "5c9eeac41b290a3712d88851518825ad78f45c71", + "shasum": "" + }, + "require": { + "php": ">=7.3", + "sebastian/object-reflector": "^2.0", + "sebastian/recursion-context": "^4.0" + }, + "require-dev": { + "phpunit/phpunit": "^9.3" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "4.0-dev" } }, "autoload": { @@ -1514,32 +2591,42 @@ ], "description": "Traverses array structures and object graphs to enumerate all referenced objects", "homepage": "https://github.com/sebastianbergmann/object-enumerator/", - "time": "2017-02-18T15:18:39+00:00" + "support": { + "issues": "https://github.com/sebastianbergmann/object-enumerator/issues", + "source": "https://github.com/sebastianbergmann/object-enumerator/tree/4.0.4" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } + ], + "time": "2020-10-26T13:12:34+00:00" }, { - "name": "sebastian/recursion-context", - "version": "2.0.0", + "name": "sebastian/object-reflector", + "version": "2.0.4", "source": { "type": "git", - "url": "https://github.com/sebastianbergmann/recursion-context.git", - "reference": "2c3ba150cbec723aa057506e73a8d33bdb286c9a" + "url": "https://github.com/sebastianbergmann/object-reflector.git", + "reference": "b4f479ebdbf63ac605d183ece17d8d7fe49c15c7" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/recursion-context/zipball/2c3ba150cbec723aa057506e73a8d33bdb286c9a", - "reference": "2c3ba150cbec723aa057506e73a8d33bdb286c9a", + "url": "https://api.github.com/repos/sebastianbergmann/object-reflector/zipball/b4f479ebdbf63ac605d183ece17d8d7fe49c15c7", + "reference": "b4f479ebdbf63ac605d183ece17d8d7fe49c15c7", "shasum": "" }, "require": { - "php": ">=5.3.3" + "php": ">=7.3" }, "require-dev": { - "phpunit/phpunit": "~4.4" + "phpunit/phpunit": "^9.3" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "2.0.x-dev" + "dev-master": "2.0-dev" } }, "autoload": { @@ -1553,13 +2640,68 @@ ], "authors": [ { - "name": "Jeff Welch", - "email": "whatthejeff@gmail.com" - }, + "name": "Sebastian Bergmann", + "email": "sebastian@phpunit.de" + } + ], + "description": "Allows reflection of object attributes, including inherited and non-public ones", + "homepage": "https://github.com/sebastianbergmann/object-reflector/", + "support": { + "issues": "https://github.com/sebastianbergmann/object-reflector/issues", + "source": "https://github.com/sebastianbergmann/object-reflector/tree/2.0.4" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } + ], + "time": "2020-10-26T13:14:26+00:00" + }, + { + "name": "sebastian/recursion-context", + "version": "4.0.4", + "source": { + "type": "git", + "url": "https://github.com/sebastianbergmann/recursion-context.git", + "reference": "cd9d8cf3c5804de4341c283ed787f099f5506172" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/sebastianbergmann/recursion-context/zipball/cd9d8cf3c5804de4341c283ed787f099f5506172", + "reference": "cd9d8cf3c5804de4341c283ed787f099f5506172", + "shasum": "" + }, + "require": { + "php": ">=7.3" + }, + "require-dev": { + "phpunit/phpunit": "^9.3" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "4.0-dev" + } + }, + "autoload": { + "classmap": [ + "src/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "BSD-3-Clause" + ], + "authors": [ { "name": "Sebastian Bergmann", "email": "sebastian@phpunit.de" }, + { + "name": "Jeff Welch", + "email": "whatthejeff@gmail.com" + }, { "name": "Adam Harvey", "email": "aharvey@php.net" @@ -1567,29 +2709,42 @@ ], "description": "Provides functionality to recursively process PHP variables", "homepage": "http://www.github.com/sebastianbergmann/recursion-context", - "time": "2016-11-19T07:33:16+00:00" + "support": { + "issues": "https://github.com/sebastianbergmann/recursion-context/issues", + "source": "https://github.com/sebastianbergmann/recursion-context/tree/4.0.4" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } + ], + "time": "2020-10-26T13:17:30+00:00" }, { "name": "sebastian/resource-operations", - "version": "1.0.0", + "version": "3.0.3", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/resource-operations.git", - "reference": "ce990bb21759f94aeafd30209e8cfcdfa8bc3f52" + "reference": "0f4443cb3a1d92ce809899753bc0d5d5a8dd19a8" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/resource-operations/zipball/ce990bb21759f94aeafd30209e8cfcdfa8bc3f52", - "reference": "ce990bb21759f94aeafd30209e8cfcdfa8bc3f52", + "url": "https://api.github.com/repos/sebastianbergmann/resource-operations/zipball/0f4443cb3a1d92ce809899753bc0d5d5a8dd19a8", + "reference": "0f4443cb3a1d92ce809899753bc0d5d5a8dd19a8", "shasum": "" }, "require": { - "php": ">=5.6.0" + "php": ">=7.3" + }, + "require-dev": { + "phpunit/phpunit": "^9.0" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "1.0.x-dev" + "dev-master": "3.0-dev" } }, "autoload": { @@ -1609,29 +2764,95 @@ ], "description": "Provides a list of PHP built-in functions that operate on resources", "homepage": "https://www.github.com/sebastianbergmann/resource-operations", - "time": "2015-07-28T20:34:47+00:00" + "support": { + "issues": "https://github.com/sebastianbergmann/resource-operations/issues", + "source": "https://github.com/sebastianbergmann/resource-operations/tree/3.0.3" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } + ], + "time": "2020-09-28T06:45:17+00:00" }, { - "name": "sebastian/version", - "version": "2.0.1", + "name": "sebastian/type", + "version": "2.3.1", "source": { "type": "git", - "url": "https://github.com/sebastianbergmann/version.git", - "reference": "99732be0ddb3361e16ad77b68ba41efc8e979019" + "url": "https://github.com/sebastianbergmann/type.git", + "reference": "81cd61ab7bbf2de744aba0ea61fae32f721df3d2" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/version/zipball/99732be0ddb3361e16ad77b68ba41efc8e979019", - "reference": "99732be0ddb3361e16ad77b68ba41efc8e979019", + "url": "https://api.github.com/repos/sebastianbergmann/type/zipball/81cd61ab7bbf2de744aba0ea61fae32f721df3d2", + "reference": "81cd61ab7bbf2de744aba0ea61fae32f721df3d2", "shasum": "" }, "require": { - "php": ">=5.6" + "php": ">=7.3" + }, + "require-dev": { + "phpunit/phpunit": "^9.3" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "2.0.x-dev" + "dev-master": "2.3-dev" + } + }, + "autoload": { + "classmap": [ + "src/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "BSD-3-Clause" + ], + "authors": [ + { + "name": "Sebastian Bergmann", + "email": "sebastian@phpunit.de", + "role": "lead" + } + ], + "description": "Collection of value objects that represent the types of the PHP type system", + "homepage": "https://github.com/sebastianbergmann/type", + "support": { + "issues": "https://github.com/sebastianbergmann/type/issues", + "source": "https://github.com/sebastianbergmann/type/tree/2.3.1" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } + ], + "time": "2020-10-26T13:18:59+00:00" + }, + { + "name": "sebastian/version", + "version": "3.0.2", + "source": { + "type": "git", + "url": "https://github.com/sebastianbergmann/version.git", + "reference": "c6c1022351a901512170118436c764e473f6de8c" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/sebastianbergmann/version/zipball/c6c1022351a901512170118436c764e473f6de8c", + "reference": "c6c1022351a901512170118436c764e473f6de8c", + "shasum": "" + }, + "require": { + "php": ">=7.3" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "3.0-dev" } }, "autoload": { @@ -1652,24 +2873,101 @@ ], "description": "Library that helps with managing the version number of Git-hosted PHP projects", "homepage": "https://github.com/sebastianbergmann/version", - "time": "2016-10-03T07:35:21+00:00" + "support": { + "issues": "https://github.com/sebastianbergmann/version/issues", + "source": "https://github.com/sebastianbergmann/version/tree/3.0.2" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } + ], + "time": "2020-09-28T06:39:44+00:00" }, { - "name": "symfony/polyfill-ctype", - "version": "v1.13.1", + "name": "symfony/deprecation-contracts", + "version": "v2.4.0", "source": { "type": "git", - "url": "https://github.com/symfony/polyfill-ctype.git", - "reference": "f8f0b461be3385e56d6de3dbb5a0df24c0c275e3" + "url": "https://github.com/symfony/deprecation-contracts.git", + "reference": "5f38c8804a9e97d23e0c8d63341088cd8a22d627" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/polyfill-ctype/zipball/f8f0b461be3385e56d6de3dbb5a0df24c0c275e3", - "reference": "f8f0b461be3385e56d6de3dbb5a0df24c0c275e3", + "url": "https://api.github.com/repos/symfony/deprecation-contracts/zipball/5f38c8804a9e97d23e0c8d63341088cd8a22d627", + "reference": "5f38c8804a9e97d23e0c8d63341088cd8a22d627", "shasum": "" }, "require": { - "php": ">=5.3.3" + "php": ">=7.1" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-main": "2.4-dev" + }, + "thanks": { + "name": "symfony/contracts", + "url": "https://github.com/symfony/contracts" + } + }, + "autoload": { + "files": [ + "function.php" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Nicolas Grekas", + "email": "p@tchwork.com" + }, + { + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" + } + ], + "description": "A generic function and convention to trigger deprecation notices", + "homepage": "https://symfony.com", + "support": { + "source": "https://github.com/symfony/deprecation-contracts/tree/v2.4.0" + }, + "funding": [ + { + "url": "https://symfony.com/sponsor", + "type": "custom" + }, + { + "url": "https://github.com/fabpot", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", + "type": "tidelift" + } + ], + "time": "2021-03-23T23:28:01+00:00" + }, + { + "name": "symfony/polyfill-ctype", + "version": "v1.22.1", + "source": { + "type": "git", + "url": "https://github.com/symfony/polyfill-ctype.git", + "reference": "c6c942b1ac76c82448322025e084cadc56048b4e" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/symfony/polyfill-ctype/zipball/c6c942b1ac76c82448322025e084cadc56048b4e", + "reference": "c6c942b1ac76c82448322025e084cadc56048b4e", + "shasum": "" + }, + "require": { + "php": ">=7.1" }, "suggest": { "ext-ctype": "For best performance" @@ -1677,7 +2975,11 @@ "type": "library", "extra": { "branch-alias": { - "dev-master": "1.13-dev" + "dev-main": "1.22-dev" + }, + "thanks": { + "name": "symfony/polyfill", + "url": "https://github.com/symfony/polyfill" } }, "autoload": { @@ -1710,41 +3012,220 @@ "polyfill", "portable" ], - "time": "2019-11-27T13:56:44+00:00" + "support": { + "source": "https://github.com/symfony/polyfill-ctype/tree/v1.22.1" + }, + "funding": [ + { + "url": "https://symfony.com/sponsor", + "type": "custom" + }, + { + "url": "https://github.com/fabpot", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", + "type": "tidelift" + } + ], + "time": "2021-01-07T16:49:33+00:00" }, { - "name": "symfony/yaml", - "version": "v3.4.36", + "name": "symfony/polyfill-mbstring", + "version": "v1.22.1", "source": { "type": "git", - "url": "https://github.com/symfony/yaml.git", - "reference": "dab657db15207879217fc81df4f875947bf68804" + "url": "https://github.com/symfony/polyfill-mbstring.git", + "reference": "5232de97ee3b75b0360528dae24e73db49566ab1" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/yaml/zipball/dab657db15207879217fc81df4f875947bf68804", - "reference": "dab657db15207879217fc81df4f875947bf68804", + "url": "https://api.github.com/repos/symfony/polyfill-mbstring/zipball/5232de97ee3b75b0360528dae24e73db49566ab1", + "reference": "5232de97ee3b75b0360528dae24e73db49566ab1", "shasum": "" }, "require": { - "php": "^5.5.9|>=7.0.8", - "symfony/polyfill-ctype": "~1.8" - }, - "conflict": { - "symfony/console": "<3.4" - }, - "require-dev": { - "symfony/console": "~3.4|~4.0" + "php": ">=7.1" }, "suggest": { - "symfony/console": "For validating YAML files using the lint command" + "ext-mbstring": "For best performance" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "3.4-dev" + "dev-main": "1.22-dev" + }, + "thanks": { + "name": "symfony/polyfill", + "url": "https://github.com/symfony/polyfill" } }, + "autoload": { + "psr-4": { + "Symfony\\Polyfill\\Mbstring\\": "" + }, + "files": [ + "bootstrap.php" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Nicolas Grekas", + "email": "p@tchwork.com" + }, + { + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" + } + ], + "description": "Symfony polyfill for the Mbstring extension", + "homepage": "https://symfony.com", + "keywords": [ + "compatibility", + "mbstring", + "polyfill", + "portable", + "shim" + ], + "support": { + "source": "https://github.com/symfony/polyfill-mbstring/tree/v1.22.1" + }, + "funding": [ + { + "url": "https://symfony.com/sponsor", + "type": "custom" + }, + { + "url": "https://github.com/fabpot", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", + "type": "tidelift" + } + ], + "time": "2021-01-22T09:19:47+00:00" + }, + { + "name": "symfony/polyfill-php80", + "version": "v1.22.1", + "source": { + "type": "git", + "url": "https://github.com/symfony/polyfill-php80.git", + "reference": "dc3063ba22c2a1fd2f45ed856374d79114998f91" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/symfony/polyfill-php80/zipball/dc3063ba22c2a1fd2f45ed856374d79114998f91", + "reference": "dc3063ba22c2a1fd2f45ed856374d79114998f91", + "shasum": "" + }, + "require": { + "php": ">=7.1" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-main": "1.22-dev" + }, + "thanks": { + "name": "symfony/polyfill", + "url": "https://github.com/symfony/polyfill" + } + }, + "autoload": { + "psr-4": { + "Symfony\\Polyfill\\Php80\\": "" + }, + "files": [ + "bootstrap.php" + ], + "classmap": [ + "Resources/stubs" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Ion Bazan", + "email": "ion.bazan@gmail.com" + }, + { + "name": "Nicolas Grekas", + "email": "p@tchwork.com" + }, + { + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" + } + ], + "description": "Symfony polyfill backporting some PHP 8.0+ features to lower PHP versions", + "homepage": "https://symfony.com", + "keywords": [ + "compatibility", + "polyfill", + "portable", + "shim" + ], + "support": { + "source": "https://github.com/symfony/polyfill-php80/tree/v1.22.1" + }, + "funding": [ + { + "url": "https://symfony.com/sponsor", + "type": "custom" + }, + { + "url": "https://github.com/fabpot", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", + "type": "tidelift" + } + ], + "time": "2021-01-07T16:49:33+00:00" + }, + { + "name": "symfony/yaml", + "version": "v5.2.5", + "source": { + "type": "git", + "url": "https://github.com/symfony/yaml.git", + "reference": "298a08ddda623485208506fcee08817807a251dd" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/symfony/yaml/zipball/298a08ddda623485208506fcee08817807a251dd", + "reference": "298a08ddda623485208506fcee08817807a251dd", + "shasum": "" + }, + "require": { + "php": ">=7.2.5", + "symfony/deprecation-contracts": "^2.1", + "symfony/polyfill-ctype": "~1.8" + }, + "conflict": { + "symfony/console": "<4.4" + }, + "require-dev": { + "symfony/console": "^4.4|^5.0" + }, + "suggest": { + "symfony/console": "For validating YAML files using the lint command" + }, + "bin": [ + "Resources/bin/yaml-lint" + ], + "type": "library", "autoload": { "psr-4": { "Symfony\\Component\\Yaml\\": "" @@ -1767,36 +3248,112 @@ "homepage": "https://symfony.com/contributors" } ], - "description": "Symfony Yaml Component", + "description": "Loads and dumps YAML files", "homepage": "https://symfony.com", - "time": "2019-10-24T15:33:53+00:00" + "support": { + "source": "https://github.com/symfony/yaml/tree/v5.2.5" + }, + "funding": [ + { + "url": "https://symfony.com/sponsor", + "type": "custom" + }, + { + "url": "https://github.com/fabpot", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", + "type": "tidelift" + } + ], + "time": "2021-03-06T07:59:01+00:00" }, { - "name": "vlucas/phpdotenv", - "version": "v3.3.2", + "name": "theseer/tokenizer", + "version": "1.2.0", "source": { "type": "git", - "url": "https://github.com/vlucas/phpdotenv.git", - "reference": "1ee9369cfbf26cfcf1f2515d98f15fab54e9647a" + "url": "https://github.com/theseer/tokenizer.git", + "reference": "75a63c33a8577608444246075ea0af0d052e452a" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/vlucas/phpdotenv/zipball/1ee9369cfbf26cfcf1f2515d98f15fab54e9647a", - "reference": "1ee9369cfbf26cfcf1f2515d98f15fab54e9647a", + "url": "https://api.github.com/repos/theseer/tokenizer/zipball/75a63c33a8577608444246075ea0af0d052e452a", + "reference": "75a63c33a8577608444246075ea0af0d052e452a", "shasum": "" }, "require": { - "php": "^5.4 || ^7.0", - "phpoption/phpoption": "^1.5", - "symfony/polyfill-ctype": "^1.9" + "ext-dom": "*", + "ext-tokenizer": "*", + "ext-xmlwriter": "*", + "php": "^7.2 || ^8.0" + }, + "type": "library", + "autoload": { + "classmap": [ + "src/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "BSD-3-Clause" + ], + "authors": [ + { + "name": "Arne Blankerts", + "email": "arne@blankerts.de", + "role": "Developer" + } + ], + "description": "A small library for converting tokenized PHP source code into XML and potentially other formats", + "support": { + "issues": "https://github.com/theseer/tokenizer/issues", + "source": "https://github.com/theseer/tokenizer/tree/master" + }, + "funding": [ + { + "url": "https://github.com/theseer", + "type": "github" + } + ], + "time": "2020-07-12T23:59:07+00:00" + }, + { + "name": "vlucas/phpdotenv", + "version": "v5.3.0", + "source": { + "type": "git", + "url": "https://github.com/vlucas/phpdotenv.git", + "reference": "b3eac5c7ac896e52deab4a99068e3f4ab12d9e56" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/vlucas/phpdotenv/zipball/b3eac5c7ac896e52deab4a99068e3f4ab12d9e56", + "reference": "b3eac5c7ac896e52deab4a99068e3f4ab12d9e56", + "shasum": "" + }, + "require": { + "ext-pcre": "*", + "graham-campbell/result-type": "^1.0.1", + "php": "^7.1.3 || ^8.0", + "phpoption/phpoption": "^1.7.4", + "symfony/polyfill-ctype": "^1.17", + "symfony/polyfill-mbstring": "^1.17", + "symfony/polyfill-php80": "^1.17" }, "require-dev": { - "phpunit/phpunit": "^4.8.35 || ^5.0 || ^6.0" + "bamarni/composer-bin-plugin": "^1.4.1", + "ext-filter": "*", + "phpunit/phpunit": "^7.5.20 || ^8.5.14 || ^9.5.1" + }, + "suggest": { + "ext-filter": "Required to use the boolean validator." }, "type": "library", "extra": { "branch-alias": { - "dev-master": "3.3-dev" + "dev-master": "5.3-dev" } }, "autoload": { @@ -1809,10 +3366,15 @@ "BSD-3-Clause" ], "authors": [ + { + "name": "Graham Campbell", + "email": "graham@alt-three.com", + "homepage": "https://gjcampbell.co.uk/" + }, { "name": "Vance Lucas", "email": "vance@vancelucas.com", - "homepage": "http://www.vancelucas.com" + "homepage": "https://vancelucas.com/" } ], "description": "Loads environment variables from `.env` to `getenv()`, `$_ENV` and `$_SERVER` automagically.", @@ -1821,34 +3383,51 @@ "env", "environment" ], - "time": "2019-01-30T10:43:17+00:00" + "support": { + "issues": "https://github.com/vlucas/phpdotenv/issues", + "source": "https://github.com/vlucas/phpdotenv/tree/v5.3.0" + }, + "funding": [ + { + "url": "https://github.com/GrahamCampbell", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/vlucas/phpdotenv", + "type": "tidelift" + } + ], + "time": "2021-01-20T15:23:13+00:00" }, { "name": "webmozart/assert", - "version": "1.4.0", + "version": "1.10.0", "source": { "type": "git", - "url": "https://github.com/webmozart/assert.git", - "reference": "83e253c8e0be5b0257b881e1827274667c5c17a9" + "url": "https://github.com/webmozarts/assert.git", + "reference": "6964c76c7804814a842473e0c8fd15bab0f18e25" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/webmozart/assert/zipball/83e253c8e0be5b0257b881e1827274667c5c17a9", - "reference": "83e253c8e0be5b0257b881e1827274667c5c17a9", + "url": "https://api.github.com/repos/webmozarts/assert/zipball/6964c76c7804814a842473e0c8fd15bab0f18e25", + "reference": "6964c76c7804814a842473e0c8fd15bab0f18e25", "shasum": "" }, "require": { - "php": "^5.3.3 || ^7.0", + "php": "^7.2 || ^8.0", "symfony/polyfill-ctype": "^1.8" }, + "conflict": { + "phpstan/phpstan": "<0.12.20", + "vimeo/psalm": "<4.6.1 || 4.6.2" + }, "require-dev": { - "phpunit/phpunit": "^4.6", - "sebastian/version": "^1.0.1" + "phpunit/phpunit": "^8.5.13" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "1.3-dev" + "dev-master": "1.10-dev" } }, "autoload": { @@ -1872,12 +3451,18 @@ "check", "validate" ], - "time": "2018-12-25T11:19:39+00:00" + "support": { + "issues": "https://github.com/webmozarts/assert/issues", + "source": "https://github.com/webmozarts/assert/tree/1.10.0" + }, + "time": "2021-03-09T10:59:23+00:00" } ], "aliases": [], "minimum-stability": "stable", - "stability-flags": [], + "stability-flags": { + "roave/security-advisories": 20 + }, "prefer-stable": false, "prefer-lowest": false, "platform": { @@ -1887,5 +3472,6 @@ "ext-simplexml": "*", "ext-libxml": "*" }, - "platform-dev": [] + "platform-dev": [], + "plugin-api-version": "2.0.0" }