jquery(xpath,function)

This is a swiss-knife command. Can do (almost) anything.

Searches for jquery xpath, starting from hat.root(), so that can be modified to search for a non-document wide region.

All jquery elements are filtered to be:

  1. visible (not display: none, not visibility: hidden)
  2. on-screen (visible by user) (behavior can be changed via auto_scroll and filter_onscreen options)

If no elements are found, tester will for maximum of max_wait_cnt option ticks before fail. 

Example:

hat.jquery(".myclass",function(el) { el.click(); } );

Arguments:

Datatype Description
xpath Search xpath (to be applied to root() and filterd)
function(el) {} Function to be called after xpath evaluated successfully