The first release of Web Performance Tester (WPT) with real browser support allow users to select items from a drop-down list (an HTML Select element) based on the text visible to a human user – just like a real user would do. There are times, however, when choosing based on the position in the list (index) or the hidden value of the selection makes a testcase more robust. This is especially true when the text descriptions of the choices may change due to variations in language, software changes, etc.
Starting with version 6.5, real-browser testcases can be configured to select by the index or the (hidden) value of the choice, as assigned by the underlying HTML code.
Pressing the tools button (wrench icon) shows the choices for the Select option step. The default mode (Autodetect…) will correctly select the right choice in most cases, but you can force one of the three selection modes by selecting a choice from that list. Note that testcases upgraded from WPT versions prior to 6.5 will be set to the visible text option, to ensure consistent behavior with those versions.
As always, comment below or contact us with any questions!
Chris Merrill, Chief Engineer