import { describe, it } from "vitest"; import { Dictionary, Expect, Test, } from "inferred-types/types"; import { RemoveVariants } from "~"; import { AssertEqual, EmptyObject } from "inferred-types"; describe("RemoveVariants", () => { it("no schema", () => { type T = RemoveVariants>; type cases = [ Expect>, ]; }); it("explicit empty object", () => { type T = RemoveVariants; type cases = [ Expect>, ]; }); it("single static entry", () => { type T = RemoveVariants<{foo: "foo"}>; type cases = [ Expect>, ]; }); it("only variants in schema", () => { type T = RemoveVariants<{foo: "foo" | "bar"; bar: "foo" | "bar"}>; type cases = [ Expect>, ]; }); it("mix of static and variants in schema", () => { type T = RemoveVariants<{foo: "foo"; bar: "foo" | "bar"}>; type cases = [ Expect>, ]; }); });