Most continuous integration platforms limit the number of threads one can use. If you have more than one test suite running puppeteer chances are that your test will timeout. This is because jest will try to run puppeteer in parallel and the CI platform won't be able to handle all the parallel jobs in time. A fix to this is to run your test serially when in a CI environment. Users have discovered that running test serially in such environments can render up to 50% of performance gains. Writing integration test can be done using Puppeteer API but it can be complicated and hard because API is not designed for testing. Debugging tests can be hard sometimes and it is very useful to be able to pause tests in order to inspect the browser. Jest Puppeteer exposes a method jestPuppeteer.debug() that suspends test execution and gives you the opportunity to see what's going on in the browser.

Features

  • Jest Puppeteer integrates a functionality to start a server when running your test suite
  • It automatically closes the server when tests are done
  • Jest Puppeteer automatically detects the best config to start Puppeteer
  • Jest Puppeteer exposes three new globals: browser, page, context
  • You may want to consider using multiple projects in Jest
  • Create your own globalSetup and globalTeardown

Project Samples

Project Activity

See All Activity >

License

MIT License

Follow Jest Puppeteer

Jest Puppeteer Web Site

Other Useful Business Software
$300 in Free Credit Towards Top Cloud Services Icon
$300 in Free Credit Towards Top Cloud Services

Build VMs, containers, AI, databases, storage—all in one place.

Start your project in minutes. After credits run out, 20+ products include free monthly usage. Only pay when you're ready to scale.
Get Started
Rate This Project
Login To Rate This Project

User Reviews

Be the first to post a review of Jest Puppeteer!

Additional Project Details

Programming Language

JavaScript

Related Categories

JavaScript Software Testing Tool, JavaScript CI CD

Registered

2022-05-03