As a developer I want to create a directory named ‘seeds’ and add files with each containing an object array consisting of the relevant property fields. These files to link to other seed files through primary and secondary keys. To import the models file and be able to export the bulk data.
I then want to populate each file/object/field with an initial set of data. This is referred to as test or dummy data,
Next, I want to create a seed.js file that contains the commands to synchronize with Sequelize to connect and populate the database with the data.
User Acceptance
When I have installed node.js.
When I have created a seeds folder in my project directory.
When I have created the following seed files within this folder:
playlist.js
songs.js
When I have created object arrays within each file with the relevant property fields.
When I have populated the property fields with the initial data set.
When I linked these files to the models folder and written the code to export the bulk data.
When I have created the userdata.json file and populated it with data containing the name, email address and password of multiple users.
When I have created the seed.js file and written the code to require the necessary files, connected to the database (Sequelize) and written a function to seed the user, songs and playlists. That is, populated the mixmate_db database.
I have successfully run the command ‘npm run seed’.
User Story
As a developer I want to create a directory named ‘seeds’ and add files with each containing an object array consisting of the relevant property fields. These files to link to other seed files through primary and secondary keys. To import the models file and be able to export the bulk data.
I then want to populate each file/object/field with an initial set of data. This is referred to as test or dummy data,
Next, I want to create a seed.js file that contains the commands to synchronize with Sequelize to connect and populate the database with the data.
User Acceptance
When I have installed node.js.
When I have created a seeds folder in my project directory.
When I have created the following seed files within this folder:
When I have created object arrays within each file with the relevant property fields.
When I have populated the property fields with the initial data set.
When I linked these files to the models folder and written the code to export the bulk data.
When I have created the userdata.json file and populated it with data containing the name, email address and password of multiple users.
When I have created the seed.js file and written the code to require the necessary files, connected to the database (Sequelize) and written a function to seed the user, songs and playlists. That is, populated the mixmate_db database.
I have successfully run the command ‘npm run seed’.