@tsed/formio
Version:
Formio package for Ts.ED framework
17 lines (13 loc) • 404 B
text/typescript
import {Store} from "@tsed/core";
import {AlterHook} from "../domain/AlterHook.js";
import {Alter} from "./alter.js";
describe("@Alter", () => {
it("should register a hook listener", () => {
("custom")
class AlterCustom implements AlterHook {
transform() {}
}
const store = Store.from(AlterCustom);
expect(store.get("formio:alter:name")).toEqual("custom");
});
});