28 lines
955 B
TypeScript
28 lines
955 B
TypeScript
import { describe, expect, it } from "vitest";
|
|
|
|
import type { ApplicationFeatureInputs } from "../../../src/application/ports/in/application-api.ts";
|
|
import {
|
|
TECH_LOG_FEATURE_ID,
|
|
type TechLogFeatureInput,
|
|
} from "../../../src/features/tech-log/application/tech-log-feature-input.ts";
|
|
|
|
type Equal<Left, Right> =
|
|
(<Value>() => Value extends Left ? 1 : 2) extends
|
|
(<Value>() => Value extends Right ? 1 : 2)
|
|
? true
|
|
: false;
|
|
type Assert<Condition extends true> = Condition;
|
|
|
|
type TechLogFeatureInputExposesNoMissingOrAdditionalKeys = Assert<
|
|
Equal<keyof ApplicationFeatureInputs["tech-log"], "publicContent" | "createStudioGateway">
|
|
>;
|
|
type TechLogFeatureInputRegistryValueMatchesFeatureContract = Assert<
|
|
Equal<ApplicationFeatureInputs["tech-log"], TechLogFeatureInput>
|
|
>;
|
|
|
|
describe("TechLog feature input", () => {
|
|
it("uses the fixed application feature identifier", () => {
|
|
expect(TECH_LOG_FEATURE_ID).toBe("tech-log");
|
|
});
|
|
});
|