дзеркало
https://github.com/l0ng-ai/openidea.git
синхронізовано 2026-12-04 09:11:10 +02:00
Menu rows of one action repeated with object args (Run with Coverage, Profile... via run.withExecutor) shared a React key; repeated keys now get a suffix. The client defines the backend-only runConfigurations and locales plugin points so plugins contributing them no longer log 'has no client projection'. The Python Debug Server host hint now says loopback hosts listen on loopback only, matching how the listener binds.
23 рядки
936 B
TypeScript
23 рядки
936 B
TypeScript
import { describe, expect, it } from "vitest";
|
|
import { registerAction } from "@/platform/actions";
|
|
import { resolveMenuItems } from "./Menu";
|
|
|
|
describe("menu row keys", () => {
|
|
it("stay unique when one action appears with several object args", () => {
|
|
const off = registerAction({ id: "test.menuKeys.executor", title: "Run With", run: () => {} });
|
|
try {
|
|
const rows = resolveMenuItems([
|
|
{ kind: "action", action: "test.menuKeys.executor", arg: { executor: "coverage" }, label: "Coverage" },
|
|
{ kind: "action", action: "test.menuKeys.executor", arg: { executor: "profiler" }, label: "Profile" },
|
|
{ label: "Same", id: "dup", run: () => {} },
|
|
{ label: "Same", id: "dup", run: () => {} },
|
|
]);
|
|
const keys = rows.map((r) => r.key);
|
|
expect(new Set(keys).size).toBe(keys.length);
|
|
expect(keys[0]).toBe("test.menuKeys.executor");
|
|
} finally {
|
|
off();
|
|
}
|
|
});
|
|
});
|