185 search results

…please, make sure your current config really has that locally, you can debug it with: ```bash bin/console debug:config zenstruck_foundry ``` Is the locale set there? Also, make sure you're debugging this config for the environment that your Symfony application is currently using…
…the course code for this tutorial *is* now old - we'll update the tutorials soon for API Platform 3. Also, in newer projects, instead of Alice, we use Foundry for data fixtures and for resetting the database between tests - https://github.com/zenstruck/foundry Cheers!
weaverryan
weaverryan
Read Full Comment
…part where it needs to be holistic. As an exercise I'm also working on integrating zenstruck/foundry and upgrading the security as that all changed in 5.3. Currently the javascript seems to be a bit broken, this needs the liip_imagine bundle and…
…my own constructor. I realise now that it's a good idea to diff my files with the start files to check on updates that are there because of deprecations etc. There is no use statement for Zenstruck\Foundry\Proxy in the course. The error…
… Lesson learned! I kept getting a badly worded error: "User Deprecated: Since zenstruck/foundry 1.7: Calling instance method "App\Factory\QuestionFactory::createMany()" is deprecated and will be removed in 2.0, use the static "App\Factory\QuestionFactory:createMany()" method instead. If you're adding…
…below. In particular look at the single colon in the preferred method which otherwise looks exactly the same as the deprecated one. User Deprecated: Since zenstruck/foundry 1.7: Calling instance method "App\Factory\QuestionFactory::createMany()" is deprecated and will be removed in 2.0…
…from the test/monolog.yaml file. Here's an example from a different library about how to do that: https://github.com/symfony/recipes/blob/master/zenstruck/foundry/1.9/config/packages/test/zenstruck_foundry.yaml > I'm enjoying BDD, but without my logger…
weaverryan
weaverryan
Read Full Comment
…other storing mechanism About your second question. Yes, Foundry will not be installed in your production server because it's a dev dependency, so you should not depend on it but in your tests or data fixtures. If you're having problems with classes using…
MolloKhan
MolloKhan
Read Full Comment
…) 2) Since I now want to use FOUNDRY, I run into trouble, because my "PersonFactory.php" already exists in the "Factory"-folder. But if I understand the concept of FOUNDRY correct these classes will never run on production (class extentions like 'ModelFactory' will not be…
…it). However, if you have any specific Foundry questions or problems, feel free to ask them here! That might help me know what things we should talk about with it... or even ways to improve the Foundry docs (I talk frequently with its author). Cheers!
weaverryan
weaverryan
Read Full Comment
…one that would be amazing to have. ie Authentication and generating fixtures with relationships are things I would really love to have tutorials on. The documentation on zenstruck foundry is really confusing and I'm having a hell of a time getting it to work. :-/
somecallmetim
somecallmetim
Read Full Comment
…to 2.5.9 (i think it's this one), it's not working anymore about authentification. I tested 2 ways to create a User (one way with Foundry like it was before, and another way with the regular createUser method available in your tutorial…
laferte_tech
laferte_tech
Read Full Comment
…need to make some adjustments along the way. For example, in the Symfony 4 tutorials, I used a different system for loading fixtures. In Symfony 5, I use Foundry, which I much prefer. Let me know if you have any other questions or doubts. Cheers!
weaverryan
weaverryan
Read Full Comment
…can see some of the setup here using a cool library called Foundry - https://symfonycasts.com/screencast/api-platform-extending/setup. I dislike many of the tools like Alice that are mentioned by API Platform. Foundry makes added data (in fixtures and a test) an…
weaverryan
weaverryan
Read Full Comment
…there any way to define those arrays in CarFactory class so I wont be messy if I will keep it in AppFixtures? I think what you're looking for our "stories": https://github.com/zenstruck/foundry#stories - with these, you could define - using the boring…
weaverryan
weaverryan
Read Full Comment
…when I remove the `: self` the warning stops showing up in 2020.3 EAP too. But I'm just gonna use 2020.2.3 to be safe for now. Thank you for taking your time to help me! I really like foundry, it's great! :)
…before i commit my stuff into my git. The warning is as follows: Return value is expected to be 'UserFactory', '\Zenstruck\Foundry\Factory' returned Here is my code: ``` protected function initialize(): self { return $this ->afterInstantiate( function (User $user) { $user->setPassword( $this->passwordEncoder->encodePassword( $user, 'engage' ) ); } …
…dev", // 7.1.x-dev "symfony/stopwatch": "6.4.x-dev", // 6.4.x-dev "symfony/web-profiler-bundle": "6.4.x-dev", // 6.4.x-dev "zenstruck/browser": "1.x-dev", // 1.x-dev "zenstruck/foundry": "^1.36" // 1.x-dev } } ``` thank you again
…bundle": "6.1.*", "symfony/maker-bundle": "^1.41", "symfony/stopwatch": "6.1.*", "symfony/web-profiler-bundle": "6.1.*", "zenstruck/foundry": "^1.34" } } I'm using Docker desktop version 4.19.0. I start the project with docker: docker compose up -d Then the symfony server: …
…6" }, "require-dev": { "doctrine/doctrine-fixtures-bundle": "^3.4", "symfony/debug-bundle": "6.2.*", "symfony/maker-bundle": "^1.48", "symfony/var-dumper": "6.2.*", "symfony/web-profiler-bundle": "6.2.*", "zenstruck/foundry": "^1.1" }, "config": { "preferred-install": { "*": "dist" }, "sort-packages": true, "platform": {}, "allow-plugins": { "symfony…