Skip to content

gngrOrg/grinder

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

grinder

an apparatus to test gngr.

Status

We are just getting started. We are currently trying to run the css2.1 test suite. More test-suites are planned for the future.

The test code uses the WebDriver protocol to navigate and screenshot the browser. The screenshots for the test and its reference are then compared.

On gngr side, we are implementing a subset of the WebDriver protocol and will then run grinder against it.

HowTo Guide

Getting started

  • git clone this repo.
  • Download the CSS2.1 testsuite from w3c. We use the nightly-unstable package and unzip it into the root folder of this repo.
  • Setup sbt
  • Run a local server on port 8000 in the root folder of this repo. Example: python -m SimpleHTTPServer.

Preparing the tests

sbt run prepare

This will parse and filter the tests from the css2.1 reference TOC. The details of the filtered tests are then stored in data/test-cases.xml.

Running the tests

sbt run compare <browser-name> <auth-key-for-gngr>

where browser-name can be either firefox or gngr.

This will open a new browser window, navigate to the tests and their references, screenshot them and compare the images.

When running with gngr, you need to set it up first:

  • Start gngr with the -grinder-key=xyz flag (substitute xyz with any key of your choice).
  • Provide the same key to the grinder run. For example: sbt run compare gngr xyz

Pausing the tests

touch pause

in this repo root will cause tests to pause.