Skip to content
This repository has been archived by the owner on Jun 28, 2023. It is now read-only.

Take screenshot of webelement #104

Closed
obonyojimmy opened this issue May 2, 2017 · 2 comments · May be fixed by #111
Closed

Take screenshot of webelement #104

obonyojimmy opened this issue May 2, 2017 · 2 comments · May be fixed by #111

Comments

@obonyojimmy
Copy link

Id like to propose a function that extends webelements struct and can take screenshot just as the page struct does ... anyone with example please share

@sclevine
Copy link
Owner

Apologies for the delay.

This seems very straightforward to implement: https://w3c.github.io/webdriver/webdriver-spec.html#take-element-screenshot

Happy to accept a PR.

At the api package level, you'd want to implement GetScreenshot on api.Element.

Then you'd want to expose it at the agouti package level, on a Selection. It could produce a screenshot for each element selected, or fail if you don't have exactly one element selected.

johanbrandhorst pushed a commit to johanbrandhorst/agouti that referenced this issue Jul 15, 2017
Fixes sclevine#104. Adds Screenshot function to Selection and GetScreenshot to the element API.
@sclevine
Copy link
Owner

Closing this in favor of #111.

johanbrandhorst pushed a commit to johanbrandhorst/agouti that referenced this issue Jul 16, 2017
Fixes sclevine#104. Adds Screenshot function to Selection and GetScreenshot to the element API.
johanbrandhorst pushed a commit to johanbrandhorst/agouti that referenced this issue Jul 18, 2017
Fixes sclevine#104. Adds Screenshot function to Selection and GetScreenshot to the element API.
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants