From 5768b70cf856289c9a6488e3ba2053df78b7c2c7 Mon Sep 17 00:00:00 2001 From: Kael Zhang Date: Sun, 19 Dec 2021 11:48:24 +0800 Subject: [PATCH] 5.2.0: #70, #75: ts: adds more test cases for typescript --- test/ts/simple.ts | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/test/ts/simple.ts b/test/ts/simple.ts index f419375..41ecb7e 100644 --- a/test/ts/simple.ts +++ b/test/ts/simple.ts @@ -53,6 +53,16 @@ const { equal(ignored, false, 'not ignored') equal(unignored, false, 'not unignored') -// Readyonly array +// Filter an Readyonly array const readonlyPaths = ['a', 'a/b', 'foo/bar'] as const ig.filter(readonlyPaths) + +// Add an Readonly array of rules +const ig6 = ignore() +ig6.add([ig3, ig4] as const) + +// options.ignoreCase and options.allowRelativePaths +ignore({ + ignoreCase: false, + allowRelativePaths: true +})