Automated rendering tests
c42f opened this issue · comments
Claire Foster commented
As discussed at JuliaLang/METADATA.jl#6436 (review) it would be nice to have some rendering tests running in travis, though might be tricky. Some relevant parts of the discussion:
Testing in a virtualized headless environment will be "interesting" as it normally depends on a working X windows and working OpenGL 3.3 implementation to actually do anything useful. Steps for an end-to-end test could be something like:
- Ensure displaz-gui can even start in a headless environment (looks possible via
xvfb
https://docs.travis-ci.com/user/gui-and-headless-browsers/ ?) - Ensure we can get an OpenGL 3.3 context on travis (dubious? travis-ci/travis-ci#5645 )
- Implement a proper scriptable screenshot command (semi-working one at #98 )
- Create test data for displaz-gui to send via a shell script, point the camera somewhere, etc.
- Compare screenshots against reference images with an image diff algorithm of some kind.