Example app demonstrating Percy's Java Selenium integration.
This example app is an HTTP server that serves a fork of the TodoMVC Vanilla-ES6 (forked at commit c78ae12a1834a11da6236c64a0c0fb06b20b7c51).
It requires Java 8 and Maven >3.6.
The Selenium tests use ChromeDriver, which you need to install separately for your system.
On Mac OS, you can use Homebrew:
$ brew tap homebrew/cask && brew cask install chromedriver
On Windows, you can use Chocolatey:
$ choco install chromedriver
For other systems (or installation alternatives), see: https://github.com/SeleniumHQ/selenium/wiki/ChromeDriver
To compile and build a jar containing our app:
$ mvn package
To run the server:
$ java -cp target/example-percy-java-selenium-1.0-SNAPSHOT.jar io.percy.examplepercyjavaselenium.App
Then visit http://localhost:8000 to see the app in action.
To run the tests:
$ mvn test
To run Percy snapshots, first set the PERCY_TOKEN
environment variable, and then run:
$ npm run test