Add artifactUpload service to test mocks
- Adds artifactUpload mock to services object with uploadArtifact and uploadArtifacts methods - Adds ARTIFACT_UPLOAD to SERVICE_NAMES mock This ensures tests that import services or SERVICE_NAMES don't fail due to missing mock definitions. Co-authored-by: nate <nate@continue.dev>
This commit is contained in:
parent
7123eef807
commit
5920c66ea3
1 changed files with 7 additions and 0 deletions
|
|
@ -9,6 +9,12 @@ export const services = {
|
|||
getAvailableOrganizations: vi.fn(() => Promise.resolve([])),
|
||||
},
|
||||
toolPermissions: vi.mocked(new ToolPermissionService()),
|
||||
artifactUpload: {
|
||||
uploadArtifact: vi.fn(() =>
|
||||
Promise.resolve({ success: true, filename: "test.png" }),
|
||||
),
|
||||
uploadArtifacts: vi.fn(() => Promise.resolve([])),
|
||||
},
|
||||
};
|
||||
|
||||
export const reloadService = vi.fn(() => Promise.resolve(undefined));
|
||||
|
|
@ -27,4 +33,5 @@ export const SERVICE_NAMES = {
|
|||
UPDATE: "update",
|
||||
STORAGE_SYNC: "storageSync",
|
||||
AGENT_FILE: "agentFile",
|
||||
ARTIFACT_UPLOAD: "artifactUpload",
|
||||
} as const;
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue