mblarsen / fFixture

Provides an easy way of creating sample data (fixtures) for unit testing using Flourish.
http://mblarsen.github.com/fFixture
2 stars 0 forks source link

Recording seeding/filling #2

Open mblarsen opened 12 years ago

mblarsen commented 12 years ago

We are currently using this to provide a base dataset for our unit tests. For some tests we need very diverse data which is hard to create and manage, so I'm thinking to add seeding like functionality where you can add partial specifications and then have the class fill in the missing parts based on the schema.

It could be a compact format like this one inspired by zen-coding:

products*3>offerings[price:10..20]*3

or something more verbose using nested arrays.

I can provide more examples on request.

Do you find this useful?

mblarsen commented 12 years ago

A specification like implementation is on the way. Check the fFixtureSeed for what to come.