mirror of
https://github.com/penpot/penpot.git
synced 2026-11-11 12:30:35 +00:00
🐛 Fix media-processor upload-storage tests
Update media-processor dependencies (multer 2.4, vitest 5 and others) and fix mockFile to emit Buffer chunks so multer memory storage Buffer.concat works. String chunks caused TypeError and 5s timeouts in two tests. AI-assisted-by: muse-spark-1.3-contributor
This commit is contained in:
parent
27ccb32ea1
commit
c4c1c5a955
@ -17,24 +17,24 @@
|
||||
"packageManager": "pnpm@12.8.1+sha512.f64ba907507f5ceafe06c8d38e6052d0179444580ec1279ddd5bfc11cb48aa8a2644b66598e07e761da84872a9fc57d5f902b87fa49d024198d558612aabbe45",
|
||||
"dependencies": {
|
||||
"express": "^5.2.1",
|
||||
"multer": "^2.2.0",
|
||||
"multer": "^2.4.0",
|
||||
"p-queue": "^9.3.3",
|
||||
"pino": "^10.3.1",
|
||||
"pino": "^10.4.0",
|
||||
"pino-loki": "^3.0.0",
|
||||
"pino-pretty": "^13.1.3",
|
||||
"sharp": "^0.35.4",
|
||||
"zod": "^4.4.3"
|
||||
"pino-pretty": "^13.2.0",
|
||||
"sharp": "^0.35.5",
|
||||
"zod": "^4.6.5"
|
||||
},
|
||||
"devDependencies": {
|
||||
"@types/express": "^5.0.6",
|
||||
"@types/multer": "^2.0.0",
|
||||
"@types/node": "^26.3.0",
|
||||
"@types/multer": "^2.3.0",
|
||||
"@types/node": "^26.6.4",
|
||||
"@types/supertest": "^7.2.1",
|
||||
"esbuild": "^0.28.2",
|
||||
"prettier": "^3.6.2",
|
||||
"supertest": "^7.2.2",
|
||||
"tsx": "^4.23.12",
|
||||
"prettier": "^3.9.9",
|
||||
"supertest": "^7.3.1",
|
||||
"tsx": "^4.23.15",
|
||||
"typescript": "^7.0.2",
|
||||
"vitest": "^4.1.11"
|
||||
"vitest": "^5.0.3"
|
||||
}
|
||||
}
|
||||
|
||||
639
media-processor/pnpm-lock.yaml
generated
639
media-processor/pnpm-lock.yaml
generated
File diff suppressed because it is too large
Load Diff
@ -13,7 +13,7 @@ function mockReq(contentLength?: string): Request {
|
||||
}
|
||||
|
||||
function mockFile(content: string = "test content") {
|
||||
const stream = Readable.from([content]);
|
||||
const stream = Readable.from([Buffer.from(content)]);
|
||||
return {
|
||||
fieldname: "file",
|
||||
originalname: "test.txt",
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user