You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
AllureSelenide should use Selenide's screenshot implementation instead of Selenium WebDriver's implementation #1439
Currently, when AllureSelenide takes a screenshot after an assertion failure, it uses WebDriverRunner.getWebDriver() to fetch the underlying Selenium WebDriver and take a screenshot. This means that plugin libraries like com.codeborne:selenide-full-screenshot which change the Photographer don't apply to screenshots added to Allure.
What would you like to happen?
io.qameta.allure.selenide.AllureSelenide.getScreenshotBytes() should use Selenide.screenshot(OutputType.BYTES) instead of the current implementation: ((TakesScreenshot) WebDriverRunner.getWebDriver()).getScreenshotAs(OutputType.BYTES), so that Selenide plugins like selenide-full-screenshot apply correctly and consistently across a test suite and reports.
Alternatives considered
We currently workaround this by using the following custom AllureSelenide subclass, which demonstrates how the Selenide.screenshot() method can effectively replace the direct WebDriver approach:
publicfinalclassAllureSelenideFullScreenshotextendsAllureSelenide {
publicAllureSelenideFullScreenshot() {
super.screenshots(false); // disable parent class screenshot behavior; full-page screenshot is taken instead
}
@OverridepublicvoidafterEvent(final@NonNullLogEventevent) {
if (event.getStatus().equals(LogEvent.EventStatus.FAIL)) {
byte[] screenshot = Selenide.screenshot(OutputType.BYTES);
if (screenshot != null) {
Allure.attachment("Screenshot", "image/png", newByteArrayInputStream(screenshot), AttachmentOptions.empty());
}
}
super.afterEvent(event);
}
}
changed the title [-]AllureSelenide use Selenide's screenshot implementation instead of Selenium WebDriver's implementation[/-][+]AllureSelenide should use Selenide's screenshot implementation instead of Selenium WebDriver's implementation[/+]on Sep 16, 2026
Activity
[-]AllureSelenide use Selenide's screenshot implementation instead of Selenium WebDriver's implementation[/-][+]AllureSelenide should use Selenide's screenshot implementation instead of Selenium WebDriver's implementation[/+]use Selenide.screenshot for screenshots so Photographer plugins apply (…