recorder icon indicating copy to clipboard operation
recorder copied to clipboard

web.dev search results flow

Open addyosmani opened this issue 5 years ago • 1 comments

I attempted to use the recorder to do the following:

  1. Navigate to web.dev
  2. Enter "images" into the search field
  3. Click on the first result (Optimize images with Thumbor)

The first two steps complete correctly. The last step does not. I wonder if this may be due to it trying to perform the await click action prior to the fetch/render for the results DOM being ready?

const {open, click, type, submit} = require('./lib/runner.js');

open('https://web.dev', {}, async () => {
  await click('aria/searchbox[name="Search"]');
  await type('aria/searchbox[name="Search"]', 'images');
  await click('aria/link[name="Optimize images with Thumbor"]');
});

image

addyosmani avatar Jul 09 '20 18:07 addyosmani

I tried your script and it works for me. It just ends immediately after clicking the link. Do you get a stacktrace?

jschfflr avatar Jul 10 '20 10:07 jschfflr