Mischa
10/12/2021, 10:34 AM"migrate:init": "npx prisma migrate dev --name init"
- why the --name init
bit?Joël
--name init
is optional by the way, running npx prisma migrate dev
will ask for a name if a migration needs to be createdJoël
migrate deploy
would make a lot more sense, you don’t want to create a migration in a testJoël
Mischa
10/12/2021, 1:49 PMMischa
10/12/2021, 1:49 PMjest.config.js
// for prisma integration tests
// run `npm run prepare:test` in repo to make sure pg docker is running
require("dotenv-flow").config({
default_node_env: "test",
path: path.join(__dirname, "packages", "repo", "prisma"),
})
Mischa
10/12/2021, 1:49 PMMischa
10/12/2021, 1:50 PMtruncateAllTables
because it's not valid typescriptJoël
Joël
Mischa
10/13/2021, 9:09 AMJoël
Joël
Joël
Mischa
10/13/2021, 9:36 AMArray<{ tablename: string }> =
as a type param to $queryRaw?