Crawlee—A web scraping and browser automation library for Node.js to build reliable crawlers. In JavaScript and TypeScript. Extract data for AI, LLMs, RAG, or GPTs. Download HTML, PDF, JPG, PNG, and other files from websites. Works with Puppeteer, Playwright, Cheerio, JSDOM, and raw HTTP. Both headful and headless mode. With proxy rotation.
TypeScript apifyautomationcrawlercrawlingheadlessheadless-chromejavascriptnodejsnpmplaywrightpuppeteerscraperscrapingtypescriptweb-crawlerweb-crawlingweb-scraping
test: disable another too flaky assertion
Martin Adámek2e208cd5f328
diff --git a/test/autoscaling/snapshotter.test.js b/test/autoscaling/snapshotter.test.jsindex d1ee99786..7da572741 100644--- a/test/autoscaling/snapshotter.test.js+++ b/test/autoscaling/snapshotter.test.js@@ -88,10 +88,10 @@ describe('Snapshotter', () => {};const snapshotter = new Snapshotter(options);await snapshotter.start();- await new Promise((resolve) => setTimeout(resolve, 510));+ await new Promise((resolve) => setTimeout(resolve, 500));await snapshotter.stop();// const memorySnapshots = snapshotter.getMemorySample();- const eventLoopSnapshots = snapshotter.getEventLoopSample();+ // const eventLoopSnapshots = snapshotter.getEventLoopSample();const cpuSnapshots = snapshotter.getCpuSample();expect(cpuSnapshots.length).toBeGreaterThanOrEqual(5);@@ -100,7 +100,8 @@ describe('Snapshotter', () => {// this when we fully migrate to TS and get rid of the import mess that we// have now in the built index.js which prevents reasonable mocking.// expect(memorySnapshots.length).toBeGreaterThanOrEqual(5);- expect(eventLoopSnapshots.length).toBeGreaterThanOrEqual(10);+ // TODO this test is too flaky on windows, often resulting in 9, sometimes even 8+ // expect(eventLoopSnapshots.length).toBeGreaterThanOrEqual(10);});test('correctly marks CPU overloaded using Platform event', async () => {