Open art1988 opened 1 month ago
Win 10. I use Selenide 7.2.3, TestNG, maven.
I've installed Jenkins on local machine ( version Jenkins 2.452.2 ) and install Allure plugin:
import com.codeborne.selenide.Screenshots; import com.google.common.io.Files; import io.qameta.allure.Attachment; import java.io.File; import java.io.IOException; public class Screenshoter { @Attachment(value = "Page screenshot", type = "image/png") public static byte[] screenshot() { File screenshot = Screenshots.takeScreenShotAsFile(); byte[] result = null; try { result = Files.toByteArray(screenshot); } catch (IOException e) { System.err.println(e); } return result; } }
The test itself looks like this:
@Test(priority = 5) public void openByUsingEnvParam() throws IOException { Selenide.open("https://www.google.com/"); $(withText("text")).shouldBe(Condition.visible, Condition.enabled); Screenshoter.screenshot(); }
Attached screenshot in the Allure Report should be the homepage of Google.
What I want to see is actual content of web page, not the grey rectangle. Refer to screenshot:
What's more interesting is that if I run the same test via mvn clean test and then run mvn allure:serve then screenshot looks fine.
So my guess is that the issue is in allure jenkins plugin.
No response
Hello. Same happens with me. Reported in #366
Jenkins and plugins versions report
Environment
```text Paste the output here ```What Operating System are you using (both controller, and any agents involved in the problem)?
Win 10. I use Selenide 7.2.3, TestNG, maven.
I've installed Jenkins on local machine ( version Jenkins 2.452.2 ) and install Allure plugin:![a6f8a0fff9685973ab34a44a7200023a42c70949](https://github.com/jenkinsci/allure-plugin/assets/38325798/c840858d-53e2-4dce-bd28-9ad33b6884cb)
Reproduction steps
The test itself looks like this:
Expected Results
Attached screenshot in the Allure Report should be the homepage of Google.
Actual Results
What I want to see is actual content of web page, not the grey rectangle. Refer to screenshot:![43723e547c536002a0085187c3c1c00ffb107c0f](https://github.com/jenkinsci/allure-plugin/assets/38325798/f688b8ad-6ad7-423a-a770-3e287b1e9d03)
Anything else?
What's more interesting is that if I run the same test via mvn clean test and then run mvn allure:serve then screenshot looks fine.
So my guess is that the issue is in allure jenkins plugin.
Are you interested in contributing a fix?
No response