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

Is there a cache system that can be used for tests? #114

Open
VincentClair opened this issue Feb 12, 2019 · 1 comment
Open

Is there a cache system that can be used for tests? #114

VincentClair opened this issue Feb 12, 2019 · 1 comment

Comments

@VincentClair
Copy link

Hello,

Running tests with fixtures are really slow. There could be some optimization adding a cache between each load, so there is no need to rerun full Alice fixtures, but just inject SQL queries result from cache.

Something similar is done actually for fixtures objects in https://github.com/liip/LiipFunctionalTestBundle, but not for files. As their v2 alpha don't support it, I already notice it here: liip/LiipFunctionalTestBundle#476.

I don't know if its related to your bundle or their, but do you plan to add some cache ?
Thanks for your help.

@theofidry
Copy link
Owner

theofidry commented Feb 12, 2019

If one wishes to introduce a back-up like solution here I'm fine with it.

I personally don't have any plan for a cache layer of some sorts. The main bottleneck I can see so far is the ORM for which the simplest solution IMO is to:

  • have small fixture set, as I prefer to have a small dedicated fixture set per feature/scenario
  • leverage transactions to avoid truncating the whole DB or dropping/re-creating the schema

I'm aware of a couple of other solutions, but since I personally don't have any use for it I don't really feel the need to work on them. I'll however gladly consider any PR for it

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

2 participants