rc-js-util
Version:
A collection of TS and C++ utilities to help writing performant and correct applications, achieved through strict typing and (removable) invariant checking.
26 lines (23 loc) • 519 B
text/typescript
// noinspection BadExpressionStatementJS
import { TNextInt } from "./t-next-int.js";
describe("=> TNextInt", () =>
{
describe("=> lte 16", () =>
{
it("| gives the next int", () =>
{
// @ts-expect-error not next int
let int: TNextInt<15> = 17;
int = 16;
int;
});
});
describe("=> gte 17", () =>
{
it("| gives number", () =>
{
const int: TNextInt<17> = 1e6;
int;
});
});
});