UNPKG

ts-mls

Version:

[![CI](https://github.com/LukaJCB/ts-mls/actions/workflows/ci.yml/badge.svg)](https://github.com/LukaJCB/ts-mls/actions/workflows/ci.yml) [![npm version](https://badge.fury.io/js/ts-mls.svg)](https://badge.fury.io/js/ts-mls) [![Coverage Status](https://co

12 lines 630 B
import { encodeProposalOrRef, decodeProposalOrRef } from "../../src/proposalOrRefType"; import { createRoundtripTest } from "./roundtrip"; describe("ProposalOrRef roundtrip", () => { const roundtrip = createRoundtripTest(encodeProposalOrRef, decodeProposalOrRef); test("roundtrips proposal", () => { roundtrip({ proposalOrRefType: "proposal", proposal: { proposalType: "remove", remove: { removed: 1 } } }); }); test("roundtrips reference", () => { roundtrip({ proposalOrRefType: "reference", reference: new Uint8Array([1, 2, 3, 4, 5]) }); }); }); //# sourceMappingURL=proposalOrRef.test.js.map