Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

[DoctrineBridge] Determine attribute or annotation type for directories#43754

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to ourterms of service andprivacy statement. We’ll occasionally send you account related emails.

Already on GitHub?Sign in to your account

Merged
nicolas-grekas merged 1 commit intosymfony:5.4fromcinamo:5.4
Nov 2, 2021

Conversation

@cinamo
Copy link
Contributor

QA
Branch?5.4
Bug fix?yes
New feature?no
Deprecations?no
TicketsFix#43753
LicenseMIT

When loading a bundle with a Doctrine entity, this entity is automatically recognized if auto_mapping: true is set in the Doctrine DBAL configuration. This currently only works if your entity class uses annotations, not attributes; this pull request adds that possibility.

@carsonbotcarsonbot added this to the5.4 milestoneOct 26, 2021
@cinamocinamo changed the titleDetermine attribute or annotation type for directories[DoctrineBridge] Determine attribute or annotation type for directoriesOct 26, 2021
@derrabus
Copy link
Member

Can you add a test please?

@cinamo
Copy link
ContributorAuthor

cinamo commentedOct 26, 2021
edited
Loading

Can you add a test please?

@derrabus I would love to. However, the original functionality doesn't have a test to begin with. Also, this test would necessarily need to refer to external files and I don't have any idea how to do that in your test suite. Can you give me a pointer how you would go about this?

@nicolas-grekas
Copy link
Member

nicolas-grekas commentedOct 28, 2021
edited
Loading

Writing tests could be done by adding a directory with fixtures in a test folder.

derrabus reacted with thumbs up emoji

@cinamo
Copy link
ContributorAuthor

Writing tests could be done by adding a directory with fixtures in a test folder.

Thanks for the suggestion, have made a new folder with an attribute annotation entity and added a test to detect the different kind of types.

@carsonbotcarsonbot changed the title[DoctrineBridge] Determine attribute or annotation type for directoriesDetermine attribute or annotation type for directoriesNov 2, 2021
@carsonbotcarsonbot changed the titleDetermine attribute or annotation type for directories[DoctrineBridge] Determine attribute or annotation type for directoriesNov 2, 2021
@nicolas-grekas
Copy link
Member

Thank you@cinamo.

Sign up for freeto join this conversation on GitHub. Already have an account?Sign in to comment

Reviewers

@nicolas-grekasnicolas-grekasnicolas-grekas left review comments

@derrabusderrabusderrabus approved these changes

Assignees

No one assigned

Projects

None yet

Milestone

5.4

Development

Successfully merging this pull request may close these issues.

[DoctrineBridge] Attribute notation for entity in bundles is not recognized

4 participants

@cinamo@derrabus@nicolas-grekas@carsonbot

[8]ページ先頭

©2009-2025 Movatter.jp