The following is an excerpt from Goran Begic's e-book, Why HTML5 Tests the Limits of Automated Testing Solutions .
Websites that act like desktops, with drag-and-drop functions, on-page calculators, and other interactive features, are of great benefit to the user community, allowing users the accessibility and scalability of the web in a familiar application paradigm. However, these rich Internet applications (RIAs) pose special testing challenges. To ensure that the user experience is consistent and "bug-free," testers must manage multiple technologies, inconsistent browser behaviors, and highly dynamic development environments. In today's competitive software industry, teams are grappling with the additional pressure of fast-paced micro-releases on top of all this complexity. Further, testing a web page means testing the layout, the logic underneath, and multiple layers of information, which only complicates the situation.
HTML5 is intended to simplify things by incorporating functions within HTML that previously required external plug-ins. The result is a more seamless experience for most users, especially those who use multiple device types. However, without extensive testing on a variety of devices, platforms, and browsers, applications built with HTML5 can actually be less user friendly.
From a testing perspective, HTML5 introduces additional complexities. While the standard is still evolving, browser support is inconsistent and new elements require new kinds of tests. For example, if you want to use an HTML5 extension, then you must learn the extension's coding rules and the potential ripple effects that the extension may have on other technologies that the application uses. It's not just about learning and testing HTML5; it’s also about evaluating its multiplier effects on all the other evolving technologies.
All of this is hard to do manually. You would need to visually inspect lines of code or write different scripts to test each function. Even if you knew all the relevant rules for all technologies and extensions and how they relate to each other in every browser, you still would have to apply that knowledge through potentially thousands of source code lines. Can you really catch each and every issue? How long will that take? Clearly, you have to automate the testing, but how? There are many styles of automation to choose from, and one of the challenges testers face is to identify the right type of automation for the task at hand.
When it comes to testing an HTML5 interface, there are several reasons why it makes sense to automate testing by recording user interaction with the software.
1. Recorded user actions make tests more "lifelike."
Recording user actions takes all the guesswork out of the equation. You can literally see every action your users make on the website, painting a very realistic picture of the user experience. This can be of enormous benefit for a number of reasons, including providing usability feedback to the user experience designers and delivering visual aids for the developers when logging defects. Many organizations simply don't have the time to use their quality assurance professionals as anything other than literal testers. Providing essential tools like recorded tests allows them to spend more time analyzing the "number of clicks" and the overall user experience. Everybody benefits from this feedback, most importantly the users. What’s more "lifelike" than that?
2. Recorded user actions require far less labor than manual code inspection and development.
It can be difficult to determine how something in the code affects something on-screen and vice versa. Even when the connection is obvious, the relevant line numbers and screen coordinates may change when developers edit the code. That can make testing difficult by conventional methods (i.e., manual code inspection or handwritten scripts) because