diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index 508281cb9..8d5987d60 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -16,6 +16,7 @@ jobs: - 7.4 - 8.0 - 8.1 + - 8.2 steps: - uses: actions/checkout@v2 @@ -39,3 +40,4 @@ jobs: - run: composer run test - run: composer run lint -- --dry-run + if: ${{ matrix.php <= '8.0' }} diff --git a/composer.json b/composer.json index d92bca26b..983b3ca81 100644 --- a/composer.json +++ b/composer.json @@ -13,6 +13,7 @@ "doctrine/orm": "^2.7" }, "require-dev": { + "doctrine/cache": "^1.11", "friendsofphp/php-cs-fixer": "^2.14", "nesbot/carbon": "*", "phpunit/phpunit": "^7.0 || ^8.0 || ^9.0", diff --git a/src/Query/Mysql/CharLength.php b/src/Query/Mysql/CharLength.php index cdc3c0a8e..59dc68389 100644 --- a/src/Query/Mysql/CharLength.php +++ b/src/Query/Mysql/CharLength.php @@ -10,7 +10,7 @@ */ class CharLength extends FunctionNode { - private $expr; + private $expr1; public function getSql(\Doctrine\ORM\Query\SqlWalker $sqlWalker): string { diff --git a/src/Query/Mysql/Power.php b/src/Query/Mysql/Power.php index c1dbe27c0..bc900c55e 100644 --- a/src/Query/Mysql/Power.php +++ b/src/Query/Mysql/Power.php @@ -9,6 +9,8 @@ class Power extends FunctionNode { public $arithmeticExpression; + public $power; + public function getSql(\Doctrine\ORM\Query\SqlWalker $sqlWalker): string { return 'POWER(' . $this->arithmeticExpression->dispatch($sqlWalker) . ', ' diff --git a/src/Query/Sqlite/ConcatWs.php b/src/Query/Sqlite/ConcatWs.php index 02229c7ba..d414219ce 100644 --- a/src/Query/Sqlite/ConcatWs.php +++ b/src/Query/Sqlite/ConcatWs.php @@ -63,7 +63,7 @@ public function getSql(\Doctrine\ORM\Query\SqlWalker $sqlWalker): string // Iterate over the captured expressions and add them to the query. for ($i = 1; $i < count($this->values); $i++) { if ($i > 1) { - $queryBuilder[] = " || '${separator}' || "; + $queryBuilder[] = " || '{$separator}' || "; } // Dispatch the walker on the current node. diff --git a/tests/Entities/CarbonDate.php b/tests/Entities/CarbonDate.php index af7d81450..65d3b6fe5 100644 --- a/tests/Entities/CarbonDate.php +++ b/tests/Entities/CarbonDate.php @@ -33,4 +33,24 @@ class CarbonDate * @Column(type="CarbonTime", nullable=true) */ public $time; + + /** + * @Column(type="CarbonImmutableDate", nullable=true) + */ + public $date_immutable; + + /** + * @Column(type="CarbonImmutableDateTime", nullable=true) + */ + public $datetime_immutable; + + /** + * @Column(type="CarbonImmutableDateTimeTz", nullable=true) + */ + public $datetime_tz_immutable; + + /** + * @Column(type="CarbonImmutableTime", nullable=true) + */ + public $time_immutable; } diff --git a/tests/Query/Mysql/TrigTest.php b/tests/Query/Mysql/TrigTest.php index be9971df2..7c1e6afc9 100644 --- a/tests/Query/Mysql/TrigTest.php +++ b/tests/Query/Mysql/TrigTest.php @@ -4,6 +4,8 @@ class TrigTest extends \DoctrineExtensions\Tests\Query\MysqlTestCase { + private $entity; + public function setUp(): void { parent::setUp(); diff --git a/tests/Types/CarbonDateTest.php b/tests/Types/CarbonDateTest.php index cd366e4b8..a1d32bd42 100755 --- a/tests/Types/CarbonDateTest.php +++ b/tests/Types/CarbonDateTest.php @@ -16,7 +16,7 @@ */ class CarbonDateTest extends TestCase { - public $entityManager = null; + private $em; public static function setUpBeforeClass(): void { diff --git a/tests/Types/ZendDateTest.php b/tests/Types/ZendDateTest.php index 531885348..5e133b1a3 100755 --- a/tests/Types/ZendDateTest.php +++ b/tests/Types/ZendDateTest.php @@ -12,7 +12,7 @@ */ class ZendDateTest extends TestCase { - public $entityManager = null; + private $em; public static function setUpBeforeClass(): void {