mirror of
https://github.com/openclaw/openclaw.git
synced 2026-04-06 06:41:08 +00:00
test: stabilize vertex adc regression assertions
This commit is contained in:
@@ -38,6 +38,9 @@ describe("anthropic-vertex ADC reads", () => {
|
||||
GOOGLE_APPLICATION_CREDENTIALS: "/tmp/vertex-adc.json",
|
||||
} as NodeJS.ProcessEnv;
|
||||
|
||||
existsSyncMock.mockClear();
|
||||
readFileSyncMock.mockClear();
|
||||
|
||||
expect(resolveAnthropicVertexProjectId(env)).toBe("vertex-project");
|
||||
expect(hasAnthropicVertexAvailableAuth(env)).toBe(true);
|
||||
expect(existsSyncMock).not.toHaveBeenCalled();
|
||||
|
||||
@@ -34,6 +34,9 @@ describe("hasAnthropicVertexAvailableAuth ADC preflight", () => {
|
||||
});
|
||||
|
||||
it("reads explicit ADC credentials without an existsSync preflight", () => {
|
||||
existsSyncMock.mockClear();
|
||||
readFileSyncMock.mockClear();
|
||||
|
||||
expect(
|
||||
hasAnthropicVertexAvailableAuth({
|
||||
GOOGLE_APPLICATION_CREDENTIALS: "/tmp/vertex-adc.json",
|
||||
|
||||
Reference in New Issue
Block a user