Testing Complex Interfaces and Visualizations
Testing real user interfaces is hard. It's fairly easy to unit test the low-level details. Integration tests can cover a couple more layers. But it can be very hard to test that those details add up to something useful: an actual feature.
What you'll learn
Testing real user interfaces is hard. It's fairly easy to unit test the low-level details. Integration tests can cover a couple more layers. But it can be very hard to test that those details add up to something useful, that they add up to an actual feature. Testing data visualizations adds another level of complexity. Often important features depend on interactions like hover or click-and-drag. Even worse, the end result of our code is often many-thousand-character SVG path strings that are very hard to unit test and basically impossible to read. Or maybe what we care most about is highly visual, like the color distribution of a heatmap. Now add responsive window sizing and testing becomes very icky. Automated, browser-based testing can address all of this. This talk will focus on how you can use Cypress and Happo to test actual interfaces with complex data. We can simulate real user behavior to assert that data is displayed accurately, giving us confidence that our code will keep working over time.