Files
test/test_output.txt
T

24 lines
781 B
Plaintext

FAIL test/file-cleanup.spec.ts
File Cleanup Middleware
× should delete old file when user image is updated (3 ms)
● File Cleanup Middleware › should delete old file when user image is updated
TypeError: prisma.$use is not a function
16 | beforeAll(async () => {
17 | prisma = new PrismaClient();
> 18 | (prisma as any).$use(fileCleanupMiddleware(prisma));
| ^
19 | await prisma.$connect();
20 |
21 | if (!fs.existsSync(testDir)) {
at Object.<anonymous> (test/file-cleanup.spec.ts:18:21)
Test Suites: 1 failed, 1 total
Tests: 1 failed, 1 total
Snapshots: 0 total
Time: 0.657 s, estimated 1 s
Ran all test suites matching test/file-cleanup.spec.ts.