Perf: replace for await w/ iterator

This commit is contained in:
SukkaW
2025-04-06 19:44:48 +08:00
parent 3d11fd8798
commit 1211557888
2 changed files with 39 additions and 10 deletions

View File

@@ -19,20 +19,26 @@ describe('fileEqual', () => {
true
));
it('ignore comment', async () => {
it('ignore comment 1', async () => {
await test(
['# A', 'B'],
['# B', 'B'],
true
);
await test(
['# A', '# C', 'B'],
['# A', '# D', 'B'],
true
);
});
it('ignore comment 2', () => test(
['# A', '# C', 'B'],
['# A', '# D', 'B'],
true
));
it('ignore comment 3', () => test(
['# A', '# C', 'B'],
['# A', '# D', 'A'],
false
));
it('comment more', () => test(
['# A', 'B'],
['# A', '# B', 'B'],