Open Kukunin opened 1 year ago
It's interesting, now I have multiple migrations in my project and it runs good. The bug occured when I had a single 0_init
migration. I might need to create a github repo that reproduces the bug
just had this one too.
Bug description
I'm trying to setup integration testing using Prisma and Jest. I do run
prisma migrate reset --force
command for a testing database before running the test suite. The command runs great, but there are no tables that defined in my migrations. I believe it's not an expected behavior.I could fix by running
TRUNCATE _prisma_migrations
before runningprisma migrate reset --force
, so it applies migrations one more timeHow to reproduce
npx dotenv -e .env.test -- npx prisma migrate reset --force
npx dotenv -e .env.test -- npx prisma migrate reset --force
one more timeExpected behavior
prisma migrate reset --force
should be idempotent and maintain the clean and latest state of the databasePrisma information
Environment & setup
Prisma Version