I have a visual difference snapshot test suit running on my local machine (OSX), while my remote build system (Jenkins) uses an Ubuntu 16.04 slave. The fonts render differently on Ubuntu (hence my tests all fail). I was doing a bit of research to see if I could configure Ubuntu to exactly match OSX's rendering on Chrome, but it looks like the rendering approach is a factor of platform opinion, combined with the font-rendering system.

Thus, my impression is there is no deterministic way to ensure a webpage on Ubuntu exactly visually matches what (some version of) OSX renders.

Is this correct?

  • 4
    OS X uses different fonts than Ubuntu. I don't think this is achievable - even if you get ubuntu to use exactly the same fonts at exactly the same DPI, browsers will always render HTML to suit the local environment/display/preferences/etc. And this is normal and correct because the correct way to render a HTML pages is however the user wants it to be displayed and not how some UI designer thinks it ought to look on their display, aiming for some imaginary and nonsensical "pixel perfect" ideal – cas Mar 9 '18 at 12:47
  • Haha, nah. South aussie. Agree with the "System > pixel perfection" rule. Which dictates that visual snapshots will need to be generated in Docker (sorry rest of team who are not currently using Docker! Ah well.) – Ashley Coolman Mar 9 '18 at 13:04

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.