UNPKG

@tsed/json-mapper

Version:
12 lines (8 loc) 293 B
import {Writer} from "./Writer.js"; describe("Writer", () => { it("should generate code for if/else condition", () => { const writer = new Writer(); writer.if("condition").add("return true;").else().add("return false;"); expect(writer.toString()).toMatchSnapshot(); }); });