Issues with sleep and click

Hi. I was testing a script against the google home page here:

I used this script:
sleep 5
setDOMElement name=q
setValue name=q query
sleep 5
clickAndWait name=btnK

And I ran into the following 2 issues:

  1. Both of the "sleep 5"s were not respected. The entire sequence is over in a little over 3 seconds.
  2. The clickAndWait didn’t work on the button. How should the script be modified to make it work?