-
-
Notifications
You must be signed in to change notification settings - Fork 7
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Record scenario screenshots for every step #40
Comments
An improved version would probably capture screenshot only after certain steps - eg after a page load / URL change, and before click/press/etc actions, and could then animate the captures together. Having a fixed screen size will help the animation, I think my captures so far with this were dynamically resized. |
@xurizaemon Thank you for coming up with this solution. I would assume that animation could be controlled from 2 places:
The implementation itself will be along the lines of what you suggested, but would need to use a converter to animated Gif. I will be able to work on this only in a couple of months time. Please feel free to submit a PR (even if it does not do animation yet and just captures screenshots for every step). As for filtering-out which steps to capture - it is possible to have a filtered list of existing step definitions (click/press etc), but this still need to be enabled with a tag like |
@xurizaemon Maybe we can allow to chose how the output is dumped - in a dedicated I'm not sure about gif being useful during debug because frames will be animated and would not allow to stop to assess. But it may be useful in CI to have a quick "report" of what the test did. |
As a means to share step workflows with testers, I knocked together this extremely crude addition to ScreenshotContext this morning. It captures a screenshot of each step of a tagged scenario (probably erring on the side of too many screenshots, really), and means a tester can see the output frame by frame.
From here it would not be far to output a video artefact.
Any thoughts on the approach @AlexSkrypnyk ? I'd love to contribute this in a way that makes sense alongside the rest of the project, or perhaps you know of existing solutions I'm not aware of.
Happy to turn into a PR if you want, but I don't feel it's at that level of quality yet 😁
(I mistakenly opened this at drevops/behat-steps#69 initially 🙄)
The text was updated successfully, but these errors were encountered: