MCPcopy Create free account
hub / github.com/callstack/agent-device / makeUploadRequest

Function makeUploadRequest

src/daemon/__tests__/upload.test.ts:12–14  ·  view source on GitHub ↗
(body: Buffer, headers: Record<string, string>)

Source from the content-addressed store, hash-verified

10import { runCmdSync } from '../../utils/exec.ts';
11
12function makeUploadRequest(body: Buffer, headers: Record<string, string>): IncomingMessage {
13 return Object.assign(Readable.from(body), { headers }) as IncomingMessage;
14}
15
16test('receiveUpload rejects uploads that exceed the configured content-length limit', async () => {
17 const req = makeUploadRequest(Buffer.alloc(0), {

Callers 1

upload.test.tsFile · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…