Skip to content

Conversation

@dstekanov
Copy link
Contributor

Context

The idea behind it is to not take screenshot 2 times (by Selenide and by Allure) but check if Selenide has already taken one and re-use it otherwise take a new screenshot.

Selenide issue history selenide/selenide#1002

Checklist

}

private static Optional<byte[]> getScreenshotBytes() {
return ScreenShotLaboratory.getInstance().getLastThreadScreenshot()
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

what if you are using saveScreenshots=true and make a single screenshot manually at test start? It seems like you'll get the same screenshot in all the steps

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If I understand correctly, it should not be a case because Selenide will take a separate screenshot on each fail

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@dstekanov and what if we got a case, when someone manually produces a screenshot on fail to attach it to the Main Test Result Page and not under the steps, while also wanting that screenshot to be under given step? Also what if we use Junit assertAll with selenide boolean methods?

Copy link
Contributor

@lasnamae lasnamae left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sorry, it was just a test.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants