mirror of
https://github.com/openclaw/openclaw.git
synced 2026-08-12 21:53:00 -06:00
test(models): add profile resolver fixtures
This commit is contained in:
@@ -64,6 +64,7 @@ function createCatalogContext(
|
||||
mode: "api_key",
|
||||
source: "env",
|
||||
}),
|
||||
resolveProviderAuthProfiles: () => [],
|
||||
};
|
||||
}
|
||||
|
||||
|
||||
@@ -33,6 +33,7 @@ function createCatalogContext(params: {
|
||||
mode: providerId && params.apiKeys?.[providerId] ? "api_key" : "none",
|
||||
source: providerId && params.apiKeys?.[providerId] ? "env" : "none",
|
||||
}),
|
||||
resolveProviderAuthProfiles: () => [],
|
||||
};
|
||||
}
|
||||
|
||||
|
||||
@@ -695,6 +695,7 @@ describe("resolvePluginDiscoveryProvidersRuntime", () => {
|
||||
env: {},
|
||||
resolveProviderApiKey: () => ({ apiKey: undefined }),
|
||||
resolveProviderAuth: () => ({ apiKey: undefined, mode: "none", source: "none" }),
|
||||
resolveProviderAuthProfiles: () => [],
|
||||
}),
|
||||
).resolves.toEqual({
|
||||
providers: {
|
||||
@@ -790,6 +791,7 @@ describe("resolvePluginDiscoveryProvidersRuntime", () => {
|
||||
env: {},
|
||||
resolveProviderApiKey: () => ({ apiKey: undefined }),
|
||||
resolveProviderAuth: () => ({ apiKey: undefined, mode: "none", source: "none" }),
|
||||
resolveProviderAuthProfiles: () => [],
|
||||
}),
|
||||
).resolves.toEqual({
|
||||
providers: {
|
||||
|
||||
Reference in New Issue
Block a user