mirror of
https://github.com/diegosouzapw/OmniRoute.git
synced 2026-08-18 21:22:28 +03:00
* remove: drop sunset MiMoCode provider from model catalog * remove: drop sunset MiMoCode provider from model catalog (shared.ts) Remove unused imports, types, and comments from shared.ts. * remove: MiMoCode provider (Xiaomi sunset) — executor, registry, no-auth config, icon, tests * refactor(providers): finish MiMoCode removal — sweep remaining no-auth references Drop the leftover mimocode entries from the no-auth provider controls, the translate-path snapshot, the eslint suppressions, and the #3061 auth-loop test. Re-point the fingerprint-pin (#6696) and proxy-noauth (#6272) tests at opencode, which exercises the same fingerprint path, so the removal does not break runtime behavior. Co-authored-by: diegosouzapw <8016841+diegosouzapw@users.noreply.github.com> * docs(providers): reconcile provider/executor counts after MiMoCode sunset The base's parallel doc-count sync (#10433) pinned 340 providers / 101 executors. With mimocode removed, live code has 339 providers and 100 executors; refresh the user-facing counts (package.json description, llm.txt, README/AGENTS, i18n llm.txt, provider reference, diagrams) so the check-docs-counts STRICT gate stays green. Co-authored-by: diegosouzapw <diegosouza.pw@gmail.com> * test(providers): fix orphaned mimocode references after MiMoCode sunset The sunset removed mimocode/mcode from the free-onboarding candidates and from FINGERPRINT_PROVIDERS, but two tests still referenced them: - free-provider-onboarding-setup: the mimocode->theoldllm substitution introduced duplicate 'opencode' rows (impossible given the request-set dedupe) and the wrong display name; align expectations with the actual {opencode, theoldllm} dedupe behavior and 'The Old LLM (Free)' name. - combo-system-prompt-templates-5501: resolveTargetFingerprint tested with provider 'mcode', which is no longer a fingerprint provider; point it at the remaining fingerprint provider 'opencode'. Co-authored-by: diegosouzapw <diegosouza.pw@gmail.com> --------- Co-authored-by: diegosouzapw <diegosouzapw@users.noreply.github.com> Co-authored-by: Tushar49 <Tushar49@users.noreply.github.com> Co-authored-by: diegosouzapw <8016841+diegosouzapw@users.noreply.github.com> Co-authored-by: adevwithpurpose <adevwithpurpose@users.noreply.github.com> Co-authored-by: diegosouzapw <diegosouza.pw@gmail.com>
53 lines
1.7 KiB
TypeScript
53 lines
1.7 KiB
TypeScript
/**
|
|
* Tests for noAuth provider validation:
|
|
* - Bug 1: `theoldllm` and `chipotle` missing from providerAllowsOptionalApiKey
|
|
* - `kimi` API key provider stays on the dedicated Moonshot executor
|
|
*/
|
|
import test from "node:test";
|
|
import assert from "node:assert/strict";
|
|
|
|
import {
|
|
NOAUTH_PROVIDERS,
|
|
providerAllowsOptionalApiKey,
|
|
supportsNoAuthProviderProxy,
|
|
} from "../../src/shared/constants/providers.ts";
|
|
import { hasSpecializedExecutor } from "../../open-sse/executors/index.ts";
|
|
|
|
// Bug 1: all noAuth providers should allow optional API key
|
|
for (const provider of [
|
|
"theoldllm",
|
|
"chipotle",
|
|
"opencode",
|
|
"duckduckgo-web",
|
|
"veoaifree-web",
|
|
]) {
|
|
test(`${provider} allows optional API key (noAuth provider)`, () => {
|
|
assert.equal(providerAllowsOptionalApiKey(provider), true);
|
|
});
|
|
}
|
|
|
|
// `kimi` is the hidden legacy id for Moonshot API compatibility, not Kimi Web.
|
|
test("kimi API key provider uses the specialized Moonshot executor", () => {
|
|
assert.equal(hasSpecializedExecutor("kimi"), true);
|
|
});
|
|
|
|
// no regression: kimi-web and kimi-coding still have their executors
|
|
test("kimi-web still has specialized executor", () => {
|
|
assert.equal(hasSpecializedExecutor("kimi-web"), true);
|
|
});
|
|
|
|
test("kimi-coding-apikey still has specialized executor", () => {
|
|
assert.equal(hasSpecializedExecutor("kimi-coding-apikey"), true);
|
|
});
|
|
|
|
test("provider proxy controls use a centralized no-auth capability allowlist", () => {
|
|
assert.equal(supportsNoAuthProviderProxy("opencode"), true);
|
|
assert.equal(supportsNoAuthProviderProxy("theoldllm"), true);
|
|
|
|
for (const providerId of Object.keys(NOAUTH_PROVIDERS)) {
|
|
if (providerId !== "opencode" && providerId !== "theoldllm") {
|
|
assert.equal(supportsNoAuthProviderProxy(providerId), false, providerId);
|
|
}
|
|
}
|
|
});
|