Skip to content

Never stop coding. Free MIT AI gateway: one endpoint, 375 providers (150+ free), 1,400+ models Kimi, Claude, GPT, Gemini, GLM, DeepSeek, MiniMax. Works with Claude Code, Codex, Cursor, OpenCode, Cline & Copilot. Quota-aware auto-fallback, RTK+Caveman compression saves 15-95% tokens, MCP/A2A, Desktop/PWA. Built by 900+ contributors

1.3 KB
Raw Blame
import test from "node:test";
import assert from "node:assert/strict";

import { APIKEY_PROVIDERS_GATEWAYS } from "../../src/shared/constants/providers/apikey/gateways.ts";

test("dahl freeNote mentions manual API key option", () => {
  const dahl = APIKEY_PROVIDERS_GATEWAYS.dahl;
  assert.ok(dahl.freeNote.includes("manual API key") || dahl.freeNote.includes("your own API key"), "dahl freeNote should mention manual API key option");
});

test("dahl authHint mentions manual API key option", () => {
  const dahl = APIKEY_PROVIDERS_GATEWAYS.dahl;
  assert.ok(dahl.authHint.includes("manual API key") || dahl.authHint.includes("your own API key"), "dahl authHint should mention manual API key option");
});

test("dahl apiHint mentions manual API key option", () => {
  const dahl = APIKEY_PROVIDERS_GATEWAYS.dahl;
  assert.ok(dahl.apiHint.includes("manual API key") || dahl.apiHint.includes("your own API key") || dahl.apiHint.includes("paste"), "dahl apiHint should mention manual API key option");
});

test("dahl notice text mentions manual API key option", () => {
  const dahl = APIKEY_PROVIDERS_GATEWAYS.dahl;
  assert.ok(dahl.notice.text.includes("manual API key") || dahl.notice.text.includes("your own API key"), "dahl notice should mention manual API key option");
});