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

Data-based fixtures #9

Closed
mehcode opened this issue Jul 5, 2013 · 2 comments
Closed

Data-based fixtures #9

mehcode opened this issue Jul 5, 2013 · 2 comments

Comments

@mehcode
Copy link
Collaborator

mehcode commented Jul 5, 2013

I've seen numerous factory-based and class-based fixtures. I'm thinking of something along the lines of a JSON / YAML / etc. file that stores the table data and can be loaded and dumped using a simple python API.

Close to django's implementation: https://docs.djangoproject.com/en/dev/howto/initial-data/

@kvesteri
Copy link
Owner

kvesteri commented Jul 6, 2013

This is a could idea, however I think in optimal scenario this should be an extension for factory_boy (by far the best fixture package for SQLAlchemy). JSON and YAML based fixtures can only contain a subset of functionality that factory_boy contains.

How about just contributing to: https://github.com/rbarrois/factory_boy and adding a feature there to load the factories from YAML or JSON file?

@mehcode
Copy link
Collaborator Author

mehcode commented Jul 16, 2013

Great idea. Posted an issue over at FactoryBoy/factory_boy#73.

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