Skip to content

Commit

Permalink
ci: Test Prisma migrations
Browse files Browse the repository at this point in the history
  • Loading branch information
DafyddLlyr committed Dec 6, 2024
1 parent dc81b22 commit cbbda36
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 4 deletions.
7 changes: 4 additions & 3 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -13,10 +13,11 @@
"test": "jest",
"test:watch": "jest --watch",
"test:coverage": "jest; open ./coverage/lcov-report/index.html",
"prisma:pull": "dotenv -e .env.local npx prisma db pull",
"prisma:pull": "dotenv -e .env.local -- npx prisma db pull",
"prisma:generate": "prisma generate",
"prisma:migrate": "dotenv -e .env.local npx prisma migrate dev",
"prisma:studio": "dotenv -e .env.local npx prisma studio",
"prisma:migrate": "dotenv -e .env.local -- npx prisma migrate dev",
"prisma:migrate-create-only": "dotenv -e .env.local -- npx prisma migrate dev --create-only",
"prisma:studio": "dotenv -e .env.local -- npx prisma studio",
"postinstall": "npm run prisma:generate",
"prettier": "prettier --write .",
"prepare": "husky",
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
-- AlterTable
ALTER TABLE "buildprices"
RENAME COLUMN "housetypedescription" TO "house_type_description";
2 changes: 1 addition & 1 deletion prisma/schema.prisma
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ datasource db {

model BuildPrices {
id Int @id @default(autoincrement())
houseTypeDescription String? @map("housetypedescription") @db.VarChar(250)
houseTypeDescription String? @map("house_type_description") @db.VarChar(250)
houseType String? @map("housetype") @db.VarChar(1)
priceRange String? @map("pricerange") @db.VarChar(50)
priceMid Float? @map("pricemid")
Expand Down

0 comments on commit cbbda36

Please sign in to comment.