Skip to content

When exception return screenshot #784

Answered by ziflex
Devilmaydante asked this question in Q&A
Discussion options

You must be logged in to vote

Hey,

Thanks for your question, it's quite a good one!
At this moment, the only thing I can think of is something like this:

LET doc = document(@url)
LET ok = wait_element(doc, "#my-element")?
RETURN ok ? (
  FOR el IN element(doc, "#my-element").children
      RETURN el
  ) : ({
      error: true,
      screenshot: screenshot(doc)
  })

Replies: 1 comment 1 reply

Comment options

You must be logged in to vote
1 reply
@Devilmaydante
Comment options

Answer selected by Devilmaydante
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants