Skip to content

Latest commit

 

History

History
18 lines (13 loc) · 1.26 KB

README.md

File metadata and controls

18 lines (13 loc) · 1.26 KB

This folder contains files for automated testing of Maplibre GL in real browsers using Selenium WebDriver.

Prerequisites

To run Webdriver, you'll have to install the driver for every browser you want to test in.

Running

  • Run browser tests with npm run test-browser.
  • The tests default to Chrome, but it's possible to use a different browser by setting the SELENIUM_BROWSER environment variable, e.g. like this: SELENIUM_BROWSER=firefox npm run test-browser.
  • To run on iOS Safari, use SELENIUM_BROWSER=safari::ios npm run test-browser. Make sure that the iOS device is in the same local Wifi network as your computer.
  • To run on Android Chrome, use SELENIUM_BROWSER=chrome::android npm run test-browser. Make sure that the Android device is in the same local Wifi network as your computer.
  • To run individual tests instead of the entire test suite, you can execute a test file with the TAP runner, e.g. by typing build/run-tap test/browser/zoom.test.js.