You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hello, our company has used Alice for fixture generation for a long time now we have a lot of complex fixtures in our project and we utilized parsing of indexed arrays to data formatters of our custom data fakers in Alice 2.x.
With the upgrade to Alice 3.x, however, this is no longer possible and passing of indexed arrays leads to internal token strings being given to the data fakers.
Example fixture file:
Results in value given to data faker:
I would like to ask if whether it is a bug in the new Alice version or if it was never meant to work this way and happened to work by chance in Alice 2.x. If that was the case, does anybody know of a clean way to passing indexed arrays to data fakers?
Thank you for answers and for a great library! Michal.
The text was updated successfully, but these errors were encountered:
I tried the format you recommended and it works only with a small adjustment when you take away space around the "=>".
So this works: <dynamicObjectData(<(["property1"=>intval(1)])>)>
It is a bit cumbersome to use and if there was a chance at some point, it would be great if alice supported indexed arrays by default.
For simple cases, it would be ok to put everything in a faker directly, however, in the scale of what we're building, it is unfortunately not maintainable to create custom logic for each different scenario.
Hello, our company has used Alice for fixture generation for a long time now we have a lot of complex fixtures in our project and we utilized parsing of indexed arrays to data formatters of our custom data fakers in Alice 2.x.
With the upgrade to Alice 3.x, however, this is no longer possible and passing of indexed arrays leads to internal token strings being given to the data fakers.
Example fixture file:
Results in value given to data faker:
I would like to ask if whether it is a bug in the new Alice version or if it was never meant to work this way and happened to work by chance in Alice 2.x. If that was the case, does anybody know of a clean way to passing indexed arrays to data fakers?
Thank you for answers and for a great library! Michal.
The text was updated successfully, but these errors were encountered: