KnpLabs / DoctrineBehaviors

Doctrine2 behavior traits that help handling Blameable, Loggable, Sluggable, SoftDeletable, Uuidable, Timestampable, Translatable, Tree behavior
http://knplabs.com
MIT License
913 stars 293 forks source link

Use doctrine/orm 3.0 #756

Open jfsenechal opened 7 months ago

jfsenechal commented 7 months ago

Hi,

Doctrine orm 3.0 was released yesterday, and it's good news :-) And from today when you install symfony webapp it comes with doctrine 3.0!

So I have already made progress in this implementation :

Replace use Doctrine\ORM\Mapping\ClassMetadataInfo by use Doctrine\ORM\Mapping\ClassMetadata Remove cascade 'merge'

up in composer

"doctrine/annotations": "^2.0.1" "doctrine/orm": "^3.0.0"

Ref https://github.com/doctrine/orm/blob/3.0.x/UPGRADE.md#bc-break-removed-doctrineormmappingclassmetadatainfo-class https://github.com/doctrine/orm/blob/3.0.x/UPGRADE.md#bc-break-remove-ability-to-merge-detached-entities

you can see my last commits

https://github.com/jfsenechal/DoctrineBehaviors/commits/sf7.0/

I have two failures with blameable

There were 2 failures:

1) Knp\DoctrineBehaviors\Tests\ORM\Blameable\BlameableTest::testCreate
'user' does not match expected type "object".

/var/www/doctrinebehaviors/tests/ORM/Blameable/BlameableTest.php:43

2) Knp\DoctrineBehaviors\Tests\ORM\Blameable\BlameableTest::testExtraSqlCalls
Failed asserting that actual size 3 matches expected size 7.

/var/www/doctrinebehaviors/tests/ORM/Blameable/BlameableTest.php:138
FluffyDiscord commented 7 months ago

you should keep doctrine 2.19 in the composer.json for now