Skip to content
Source
Sign inSign up
pingdotgg/t3code
Open History to see the last commit

diffCutLines.test.ts

10 lines395 Bytes

1import { assert, describe, it } from "@effect/vitest";
2​
3import { cutLineNoteStart } from "./diffCutLines.ts";
4​
5describe("cutLineNoteStart", () => {
6 it.each(["", "\r"])("finds the note without counting the line ending %j", (ending) => {
7 assert.strictEqual(cutLineNoteStart(`😀ab …[1,000 more characters]${ending}`), 5);
8 assert.isNull(cutLineNoteStart(`😀ab${ending}`));
9 });
10});