MCPcopy Index your code
hub / github.com/simstudioai/sim / makeFile

Function makeFile

apps/sim/lib/uploads/client/direct-upload.test.ts:14–18  ·  view source on GitHub ↗
(size: number, name = 'test.bin', type = 'application/octet-stream')

Source from the content-addressed store, hash-verified

12const LARGE_THRESHOLD = 50 * ONE_MB
13
14const makeFile = (size: number, name = 'test.bin', type = 'application/octet-stream'): File => {
15 const file = new File([new Uint8Array(0)], name, { type })
16 Object.defineProperty(file, 'size', { value: size })
17 return file
18}
19
20const presigned = (overrides?: Partial<PresignedUploadInfo>): PresignedUploadInfo => ({
21 fileName: 'test.bin',

Callers 1

Calls

no outgoing calls

Tested by

no test coverage detected