diff --git a/.github/workflows/test-unit.yml b/.github/workflows/test-unit.yml index 2f43d3034..1ff3ae68c 100644 --- a/.github/workflows/test-unit.yml +++ b/.github/workflows/test-unit.yml @@ -98,7 +98,7 @@ jobs: image: mysql:5.6 options: --health-cmd="mysqladmin ping" --health-interval=10s --health-timeout=5s --health-retries=5 -e MYSQL_ROOT_PASSWORD=atk4_pass_root -e MYSQL_USER=atk4_test_user -e MYSQL_PASSWORD=atk4_pass -e MYSQL_DATABASE=atk4_test mariadb: - image: mariadb + image: mariadb:11.2 options: --health-cmd="mariadb-admin ping" --health-interval=10s --health-timeout=5s --health-retries=5 -e MYSQL_ROOT_PASSWORD=atk4_pass_root -e MYSQL_USER=atk4_test_user -e MYSQL_PASSWORD=atk4_pass -e MYSQL_DATABASE=atk4_test postgres: image: postgres:12-alpine diff --git a/tests/Persistence/ArrayTest.php b/tests/Persistence/ArrayTest.php index 10453c316..78151095e 100644 --- a/tests/Persistence/ArrayTest.php +++ b/tests/Persistence/ArrayTest.php @@ -562,7 +562,7 @@ public function testOrder(): void ['f1' => 'D'], ['f1' => 'E'], ], $d); - self::assertSame($d, array_values($m->export(['f1']))); // array_values to get rid of keys + self::assertSame($d, $m->export(['f1'])); // order by one field descending $p = new Persistence\Array_($dbData); @@ -584,7 +584,7 @@ public function testOrder(): void ['f1' => 'A'], ['f1' => 'A'], ], $d); - self::assertSame($d, array_values($m->export(['f1']))); // array_values to get rid of keys + self::assertSame($d, $m->export(['f1'])); // order by two fields ascending $p = new Persistence\Array_($dbData); @@ -604,7 +604,7 @@ public function testOrder(): void ['id' => 4, 'f1' => 'A', 'f2' => 'C'], ['id' => 1, 'f1' => 'A', 'f2' => 'B'], ], $d); - self::assertSame($d, array_values($m->export(['f1', 'f2', 'id']))); // array_values to get rid of keys + self::assertSame($d, $m->export(['f1', 'f2', 'id'])); } public function testNoKeyException(): void @@ -701,14 +701,14 @@ public function testLimit(): void ['id' => 1, 'f1' => 'A'], ['id' => 2, 'f1' => 'D'], ['id' => 3, 'f1' => 'E'], - ], array_values($m->export())); + ], $m->export()); $m->setLimit(2, 1); self::assertSame(2, $m->executeCountQuery()); self::assertSame([ ['id' => 2, 'f1' => 'D'], ['id' => 3, 'f1' => 'E'], - ], array_values($m->export())); + ], $m->export()); // well, this is strange, that you can actually change limit on-the-fly and then previous // limit is not taken into account, but most likely you will never set it multiple times