Skip to content

Commit e2cdc4c

Browse files
committed
Lint
1 parent ad9ada3 commit e2cdc4c

File tree

2 files changed

+15
-6
lines changed

2 files changed

+15
-6
lines changed

.github/workflows/publish.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,4 +29,4 @@ jobs:
2929
- uses: notlmn/release-with-changelog@v3
3030
with:
3131
token: ${{ secrets.GITHUB_TOKEN }}
32-
exclude: '^Meta|^\d\.\d\.\d$|^Readme|readme$|Lint'
32+
exclude: '^Meta|^\d\.\d\.\d$|^Readme|readme$|Lint|dependencies'

test.ts

Lines changed: 14 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,10 @@ for (const [detectName, detect] of Object.entries(pageDetect)) {
2424
}
2525

2626
test(detectName + ' has tests', t => {
27-
t.true(Array.isArray(validURLs), `The function \`${detectName}\` doesn’t have any tests. Set them via \`collect.set()\``);
27+
t.true(
28+
Array.isArray(validURLs),
29+
`The function \`${detectName}\` doesn’t have any tests. Set them via \`collect.set()\``,
30+
);
2831
});
2932

3033
if (!Array.isArray(validURLs)) {
@@ -33,13 +36,16 @@ for (const [detectName, detect] of Object.entries(pageDetect)) {
3336

3437
for (const url of validURLs) {
3538
test(`${detectName} ${url.replace('https://github.com', '')}`, t => {
36-
t.true(detect(new URL(url)), stripIndent(`
39+
t.true(
40+
detect(new URL(url)),
41+
stripIndent(`
3742
Is this URL \`${detectName}\`?
3843
${url.replace('https://github.com', '')}
3944
4045
• Yes? The \`${detectName}\` test is wrong and should be fixed.
4146
• No? Remove it from its \`collect.set()\` array.
42-
`));
47+
`),
48+
);
4349
});
4450
}
4551

@@ -51,13 +57,16 @@ for (const [detectName, detect] of Object.entries(pageDetect)) {
5157
for (const url of allUrls) {
5258
if (!validURLs.includes(url)) {
5359
test(`${detectName} NO ${url}`, t => {
54-
t.false(detect(new URL(url)), stripIndent(`
60+
t.false(
61+
detect(new URL(url)),
62+
stripIndent(`
5563
Is this URL \`${detectName}\`?
5664
${url.replace('https://github.com', '')}
5765
5866
• Yes? Add it to the \`collect.set()\` array.
5967
• No? The \`${detectName}\` test is wrong and should be fixed.
60-
`));
68+
`),
69+
);
6170
});
6271
}
6372
}

0 commit comments

Comments
 (0)