Created
October 23, 2017 21:30
-
-
Save neodigm/00a54d0c7d9ab8c09ed6da724bcc29cf to your computer and use it in GitHub Desktop.
Puppeteer Headless Chrome Sample - Clear Cache - stress test
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const puppeteer = require('puppeteer'); | |
(async () => { | |
for( var i = 1; i < 501; i++){ | |
var browser = await puppeteer.launch({headless: true, slowMo: 1000}); | |
var page = await browser.newPage(); | |
page.setViewport({width: 980, height: 3200}); | |
await page.goto('https://qqqqqqqqqqq'); | |
await page.screenshot({path: 'ltdc_stage_lsc_'+i+'.png'}); | |
await browser.close(); | |
} | |
})(); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
npm install puppeteer