Tuesday, November 5, 2013

HTML5/Sencha/Ext JS Web Browser Automation

I have spent the last couple of years working heavily with Sencha Touch/Ext JS, and ran into a lot of issues when it came to writing test automation suites that run in web browsers. It is for this reason I created HTML5 Robot, which makes writing these tests easy. 

HTML5 Robot is based on a series of best practices for how to reliably lookup and interact with components based on attributes and conditions which are not dynamic. It then provides shortcuts for doing this with all of the HTML, Ext JS, and Sencha Touch components that you would need to interact with. It comes in 2 flavors: 

  1. Java - Familiar Selenium and JUnit based API that has built in web driver support for all modern browsers. 
  2. Gwen - A human style language for quickly and easily creating and maintaining browser tests, which comes with its own integrated development environment. All of which is based on the Java API. 
For example if you were wanting to click the "OK" button in an Ext JS dialog, you could do the following in Java: 

    click(findExtJsMessageBoxButtonByText("OK")); 

...and you could do the following in Gwen: 

    click extjsdialogbutton by id "OK" 

It includes extensive documentation in both Java and Gwen, outputs JUnit and its own HTML-style reports, and integrates with any build and continuous integration tool such as Ant, Gradle, and Jenkins. 

You can download the entire thing for free and check it out. Let me know if you have any questions.

No comments:

Contributors