mirror of
https://github.com/openclaw/openclaw.git
synced 2026-05-10 13:54:57 +00:00
test: migrate suites to e2e coverage layout
This commit is contained in:
12
src/agents/auth-profiles.auth-profile-cooldowns.e2e.test.ts
Normal file
12
src/agents/auth-profiles.auth-profile-cooldowns.e2e.test.ts
Normal file
@@ -0,0 +1,12 @@
|
||||
import { describe, expect, it } from "vitest";
|
||||
import { calculateAuthProfileCooldownMs } from "./auth-profiles.js";
|
||||
|
||||
describe("auth profile cooldowns", () => {
|
||||
it("applies exponential backoff with a 1h cap", () => {
|
||||
expect(calculateAuthProfileCooldownMs(1)).toBe(60_000);
|
||||
expect(calculateAuthProfileCooldownMs(2)).toBe(5 * 60_000);
|
||||
expect(calculateAuthProfileCooldownMs(3)).toBe(25 * 60_000);
|
||||
expect(calculateAuthProfileCooldownMs(4)).toBe(60 * 60_000);
|
||||
expect(calculateAuthProfileCooldownMs(5)).toBe(60 * 60_000);
|
||||
});
|
||||
});
|
||||
Reference in New Issue
Block a user