chore: remove plans and uploads from git tracking

This commit is contained in:
Kirill
2026-05-15 20:32:52 +05:00
parent 7e231dbdd8
commit d499aeb735
29 changed files with 16 additions and 1474 deletions
+10 -5
View File
@@ -14,19 +14,18 @@ describe('persistMultipartImages with eager mode', () => {
await fs.promises.unlink(path.join(UPLOADS_DIR, file)).catch(() => {})
}
}
const cacheDir = path.join(UPLOADS_DIR, '.cache')
await fs.promises.rm(cacheDir, { recursive: true, force: true }).catch(() => {})
})
it('returns WebP URLs when eager=true', async () => {
const sharp = (await import('sharp')).default
const testImagePath = path.join(UPLOADS_DIR, `${TEST_PREFIX}original.png`)
const filesBefore = await fs.promises.readdir(UPLOADS_DIR)
await sharp({ create: { width: 100, height: 100, channels: 3, background: { r: 255, g: 0, b: 0 } } })
.png()
.toFile(testImagePath)
const filesBefore = await fs.promises.readdir(UPLOADS_DIR)
const mockRequest = {
isMultipart: () => true,
parts: async function* () {
@@ -51,7 +50,13 @@ describe('persistMultipartImages with eager mode', () => {
// Verify the intermediate PNG file written by persistMultipartImages was deleted
const filesAfter = await fs.promises.readdir(UPLOADS_DIR)
const newPngFiles = filesAfter.filter((f) => !filesBefore.includes(f) && f.endsWith('.png'))
const newPngFiles = filesAfter.filter(
(f) =>
!filesBefore.includes(f) &&
f.endsWith('.png') &&
f !== path.basename(testImagePath) &&
!f.startsWith('test-eager-uuid-'),
)
expect(newPngFiles).toHaveLength(0)
})
Binary file not shown.

Before

Width:  |  Height:  |  Size: 24 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 22 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 81 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 14 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 35 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 37 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 165 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 25 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 91 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 17 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 102 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 19 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 31 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 13 KiB

-1
View File
@@ -1 +0,0 @@
Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.7 MiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.2 MiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 13 MiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.0 MiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.9 MiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 15 MiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 13 MiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 13 MiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.8 MiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.1 MiB