-
-
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
Configure screenshot name pattern in behat.yml #37
Comments
@xurizaemon Please note that there is a The timestamp prefix was added to order screenshots by creation time. |
Here is a suggested spec for providing configurable file names for screenshots. Token format
The reasoning behind using Supported tokensUsing
Based on the above, the current format can be expressed as:
resulting in filenames like:
Config changes
Success vs failed patternsAlthough adding an ability to provide different file name patterns for successful and failed screenshots is not a part of this issue, it is worth specifying how it would look like in config:
|
@tannguyen04 |
And don't miss the existing WIP in #53 :) You're welcome to squash commits on that branch to base your work on. When doing so please retain commit credit for existing progress 😄 It's fine to start over too! Thanks for picking this up 😁 |
@tannguyen04 came across the config for this in a repo today and wondered how it had progressed. Did you get anywhere? Can I help in any way? |
@xurizaemon I work with @tannguyen04 on this and the priority for this issue has changed a bit. We will be addressing this in a week or two. |
Different to #28 (which I read to mean, specifying the output filename in the stepdefinition, eg
Then I save screenshot to my-screenshot.png
).It would be nice to have control over the screenshot filename generation when the filename is not specified.
My use case would be the ability to remove the time-based uniqueness, since then the screenshot filename is based on the feature / step (or failing step), and you can hit reload in the browser to see updated HTML / PNG after a test run. Currently this workflow requires re-opening the newly generated file 😁
Just a wishlist item - looking at
makeFileName()
we'd need to introduce some interpolation of values like@featureFile
,@stepLine
to a template string I expect.The text was updated successfully, but these errors were encountered: