mirror of
https://github.com/openclaw/openclaw.git
synced 2026-05-22 03:51:18 +00:00
test: tighten huggingface provider assertion
This commit is contained in:
parent
7c86f7434d
commit
8543ba40de
1 changed files with 6 additions and 1 deletions
|
|
@ -40,7 +40,12 @@ function registerProviderWithPluginConfig(pluginConfig: Record<string, unknown>)
|
|||
);
|
||||
|
||||
expect(registerProviderMock).toHaveBeenCalledTimes(1);
|
||||
return registerProviderMock.mock.calls[0]?.[0];
|
||||
const firstCall = registerProviderMock.mock.calls.at(0);
|
||||
expect(firstCall).toBeDefined();
|
||||
if (!firstCall) {
|
||||
throw new Error("expected huggingface provider registration");
|
||||
}
|
||||
return firstCall[0];
|
||||
}
|
||||
|
||||
describe("huggingface plugin", () => {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue