Jest Demo

This shows how to use Jest for unit testing yFiles for HTML application logic.

If you want to test your yFiles application with Jest in a fully functional browser environment, see the Jest Puppeteer Demo.

You can find more information about testing a yFiles-based application in general, and about using Jest and yFiles together in particular, in the documentation.

Running the unit tests

  1. Go to the demo's directory demos-ts/testing/jest.
  2. Run npm install.
  3. Run the unit tests with npm run test.