perf: the request client upload function supports more parameters (#4439)

This commit is contained in:
Vben
2024-09-19 22:13:43 +08:00
committed by GitHub
parent 161820dbc1
commit 4765158510
3 changed files with 13 additions and 8 deletions

View File

@@ -79,7 +79,9 @@ describe('requestClient', () => {
: [400, { error: 'Bad Request' }];
});
const response = await requestClient.upload('/test/upload', fileData);
const response = await requestClient.upload('/test/upload', {
file: fileData,
});
expect(response.data).toEqual({ data: 'file uploaded' });
});