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

[Init DB with data] - Add seed mechanism #385

Merged
merged 2 commits into from
May 14, 2024

Conversation

antoineludeau
Copy link
Member

@antoineludeau antoineludeau commented Apr 17, 2024

Context

When working locally, we need to have data into the db to develop, to test, ... etc

Enhancement

This PRs aims to add a "seed" mechanism to be able to insert/modify/delete data into the DB easily thanks to sequelize-cli.

How to test

1- Run the command :
npm run seed:up

2- Check you local db : the data from the file db-migrations/seeders/20240417084446-init-districts.cjs must have been inserted into your local db.

@antoineludeau antoineludeau merged commit e0f8c0e into master May 14, 2024
1 check passed
@antoineludeau antoineludeau deleted the antoineludeau/add-seed-mechanism branch May 14, 2024 08:27
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[Ban-Plateforme] : Ajout d'un mécanisme de seed de la donnée dans la BDD pour du développement local
2 participants