Skip to content
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 our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Making a service out of doctrine:fixtures:load command #88

Open
devhelp opened this issue Jun 2, 2013 · 6 comments
Open

Making a service out of doctrine:fixtures:load command #88

devhelp opened this issue Jun 2, 2013 · 6 comments

Comments

@devhelp
Copy link

devhelp commented Jun 2, 2013

Would be great to have the command as service or to extract pure service class out of it in order to have it available in the container

@devhelp
Copy link
Author

devhelp commented Jun 12, 2013

One use case could be to use it in Symfony's WebTestCase to load fixtures for tests. I could try to create a service, how do you think, would it be useful ?

@lavoiesl
Copy link
Member

+1

@mvmaasakkers
Copy link

I've created a WIP PR: #248

Is this the general idea?

@vovan47
Copy link

vovan47 commented Oct 26, 2018

@mvmaasakkers I'd like to use it, is that project maintained? maybe we can alert authors somehow?

@alcaeus
Copy link
Member

alcaeus commented Nov 15, 2018

It is - I've just had less time to work on this than I'd hoped. I'll take care of open issues/PRs over the coming weeks - please stay tuned.

@alcaeus alcaeus added this to 3.2 in Roadmap Dec 11, 2018
@alcaeus
Copy link
Member

alcaeus commented Jun 7, 2019

I've taken a look, and we will most likely not be able to fix this in 3.x. Reason is that the underlying classes from the Doctrine data-fixtures library don't support dynamically injecting an entity manager. Since the entity manager can be passed to the command via an argument, we need to be able to inject the entity manager at runtime, which currently isn't possible.

I'm hoping to tackle this in the library soon, but it won't be in the next few weeks, since all of the executors and purgers need updating.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants