-
-
Notifications
You must be signed in to change notification settings - Fork 328
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
add reference range name builder #347
Conversation
Add current() in identity() support
Use preg_grep to filter references by mask
Cache reference keys by mask
Still no idea why the build fails, need to see if I can fix it tomorrow. |
|
||
return $fixtures; | ||
} | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
needs an empty line at the end of the file
It is weird, they do pass locally when I pull out your branch... |
# Conflicts: # src/Nelmio/Alice/Loader/Base.php
Finally I found it. I merged the latest changes in branch 2.x, it seems travis does this automatically. There were some changes so I fixed the test and the new builder to work with those changes. |
Nice! I'm waiting for #355 to be merged and then I'll merge yours :) |
Sorry @theofidry, this got totally out of my mind. I merged the latest 2.x branch now. What else is missing? |
I think there was only the tests to fix left :) I'm gonna take a new look at it and to a PR against master as well to ensure this feature is on both 2.x and 3.x. Thanks |
Closed via #693, it has been released in 2.3.0 :) |
This builder would help to create fixtures for OneToOne relations within doctrine or other ORMs.
You could reference objects created earlier in your fixtures to create the same amount of instances.
You're free to select just one object or the whole list matched by a mask. The builder then creates as many instances as matched by your mask.
The only condition is that your fixtures must be declared within different files.
I saw this pull request #236. In a way it gives the opportunity to add own builders but in my case I need the object reference. Another idea could be to implemnent an ObjectsAwareInterface which sets the current objects to a builder if required.