"Pallavi Verma" <22*0*7*[email protected]*u*e*t*u*a*e*u*a*> wrote:
> I am getting a bit confused in how to create a test database.
> Do we need to delete our migrations folder and app.db for our existing project in > order to initialize a test database?
> Will the db initialization create app.db again?
You shouldn't need to remove the app database. You just need to create a new Testing
configuration pointing to the test database. I wnet through this in the Testing
workshop. I did need to remove the migrations etc when I set up migrations for the
test database, but this was a mistake. The test database shouldn't need any
migrations as it is built just to run the tests. (Migrations are for persistent
Then the db init should just create test.db (if that's what you had in your confug
You can also set up an in-memory sqlite database;