Keep in mind that loading fixtures within the test is a huge performance bottleneck. If all tests share the same set of fixtures, its way easier to load them before the first test and use something like dama/doctrine-test-bundle that starts a transaction before each test and rolls it back afterwards
Could you please explain your comments about fixtures and test performance in more detail?
You mentioned that "loading fixtures within the test is a huge performance bottleneck." I'd like to understand:
Why does liip/test-fixtures-bundle cause performance issues? Is it because fixtures are reloaded for each individual test case?
With dama/doctrine-test-bundle, how does it work exactly? If I understand correctly, this package allows us to:
Load fixtures only once at the beginning
Then use transactions to isolate each test
But concretely, how is fixture loading organized with dama? Are fixtures loaded only once for the entire test suite, and then each test works on the same base data thanks to the transaction rollback system?
**what's the probelem of using fixtures in my tests ? And what's the recommanded way to use fake data inside my tests ?
Thanks for these clarifications!
Best regards
For further actions, you may consider blocking this person and/or reporting abuse
We're a place where coders share, stay up-to-date and grow their careers.
Keep in mind that loading fixtures within the test is a huge performance bottleneck. If all tests share the same set of fixtures, its way easier to load them before the first test and use something like
dama/doctrine-test-bundlethat starts a transaction before each test and rolls it back afterwardsHello,
Could you please explain your comments about fixtures and test performance in more detail?
You mentioned that "loading fixtures within the test is a huge performance bottleneck." I'd like to understand:
Why does liip/test-fixtures-bundle cause performance issues? Is it because fixtures are reloaded for each individual test case?
With dama/doctrine-test-bundle, how does it work exactly? If I understand correctly, this package allows us to:
But concretely, how is fixture loading organized with dama? Are fixtures loaded only once for the entire test suite, and then each test works on the same base data thanks to the transaction rollback system?
Thanks for these clarifications!
Best regards