mirror of
https://github.com/SukkaW/Surge.git
synced 2026-01-29 01:51:52 +08:00
Chore: minor changes
This commit is contained in:
12
Build/lib/process-line.bench.ts
Normal file
12
Build/lib/process-line.bench.ts
Normal file
@@ -0,0 +1,12 @@
|
||||
import { fetchRemoteTextByLine } from './fetch-text-by-line';
|
||||
import { processLine } from './process-line';
|
||||
|
||||
import { bench, run } from 'mitata';
|
||||
|
||||
(async () => {
|
||||
const data = await Array.fromAsync(await fetchRemoteTextByLine('https://filters.adtidy.org/extension/ublock/filters/3_optimized.txt', false));
|
||||
|
||||
bench('processLine', () => data.forEach(processLine));
|
||||
|
||||
run();
|
||||
})();
|
||||
@@ -1,7 +1,7 @@
|
||||
import { describe, it } from 'mocha';
|
||||
|
||||
import { processLine } from './process-line';
|
||||
import expect from 'expect';
|
||||
import { expect } from 'expect';
|
||||
|
||||
describe('processLine', () => {
|
||||
([
|
||||
|
||||
Reference in New Issue
Block a user