six2six / fixture-factory

Generator fake objects from a template
Apache License 2.0
445 stars 88 forks source link

override property definition on `gimme` call #44

Closed nykolaslima closed 10 years ago

nykolaslima commented 10 years ago

Define property's value in generated fixture on gimme call.

Example: Fixture.from(User.class).gimme("valid", "name", "nykolas");

I don't know how to call gimme passing property name and value in a nice way. Maybe if we can define a new Rule on gimme call: Fixture.from(User.class).gimme("valid", new Rule() {{ add("name", "nykolas"); }});

Do you guys have any good idea on how we can implement this? @ahirata @aparra @douglasrodrigo @bjornnborg