test: fix type for test
All checks were successful
continuous-integration/drone/push Build is passing

This commit is contained in:
鲁树人 2023-10-19 02:22:29 +01:00
parent c5910c088c
commit 57c0a247c0

View File

@ -18,15 +18,16 @@ test('should be able to forward request to worker client bus', async () => {
vi.spyOn(bus, 'request').mockImplementation(
async (actionName: DECRYPTION_WORKER_ACTION_NAME, payload: unknown): Promise<unknown> => {
return { actionName, payload };
}
},
);
const queue = new DecryptionQueue(bus, 1);
await expect(queue.add({ id: 'file://1', blobURI: 'blob://mock-file' })).resolves.toEqual({
await expect(queue.add({ id: 'file://1', blobURI: 'blob://mock-file', options: {} })).resolves.toEqual({
actionName: DECRYPTION_WORKER_ACTION_NAME.DECRYPT,
payload: {
blobURI: 'blob://mock-file',
id: 'file://1',
options: {},
},
});
});