SessionNotCreatedException : Could not start a new session. Possible causes are invalid address of the remote server or browser start-up failure

My Selenium test suite is running without any problem on my local comp. but in azure pipeline, it is running for some time without any problem,scenarios passing successfuly, than failing at random scenario(mostly third), while navigating the website. After failed, rest of the scenarios failing too and test is rınning 50-60 minutes simetimes even more. normally it should take 10-15 min. Before that, tests used to run without problem on azure. than ı start to get session not started-not quited exceptions and updated to pom dependencies. after that this errors coming. ı tried different scenarios, different profiles on pom, it does not changed the situation. Here is the error log and my project details:

first error:
Given Naviagate to Microfon FAILED 1 m 2.980 s

`io.cucumber.core.exception.CucumberException: Failed to instantiate class StepDefinitions._05_DataTableSteps
 at io.cucumber.core.backend.DefaultObjectFactory.cacheNewInstance(DefaultObjectFactory.java:67)
 at io.cucumber.core.backend.DefaultObjectFactory.getInstance(DefaultObjectFactory.java:45)
 at io.cucumber.java.AbstractGlueDefinition.invokeMethod(AbstractGlueDefinition.java:47)
 at io.cucumber.java.JavaStepDefinition.execute(JavaStepDefinition.java:29)
 at io.cucumber.core.runner.CoreStepDefinition.execute(CoreStepDefinition.java:66)
 at io.cucumber.core.runner.PickleStepDefinitionMatch.runStep(PickleStepDefinitionMatch.java:63)
 at io.cucumber.core.runner.ExecutionMode$1.execute(ExecutionMode.java:10)
 at io.cucumber.core.runner.TestStep.executeStep(TestStep.java:84)
 at io.cucumber.core.runner.TestStep.run(TestStep.java:56)
 at io.cucumber.core.runner.PickleStepTestStep.run(PickleStepTestStep.java:51)
 at io.cucumber.core.runner.TestCase.run(TestCase.java:84)
 at io.cucumber.core.runner.Runner.runPickle(Runner.java:75)
 at io.cucumber.testng.TestNGCucumberRunner.lambda$runScenario$1(TestNGCucumberRunner.java:132)
 at io.cucumber.core.runtime.CucumberExecutionContext.lambda$runTestCase$5(CucumberExecutionContext.java:137)
 at io.cucumber.core.runtime.RethrowingThrowableCollector.executeAndThrow(RethrowingThrowableCollector.java:23)
 at io.cucumber.core.runtime.CucumberExecutionContext.runTestCase(CucumberExecutionContext.java:137)
 at io.cucumber.testng.TestNGCucumberRunner.runScenario(TestNGCucumberRunner.java:129)
 at io.cucumber.testng.AbstractTestNGCucumberTests.runScenario(AbstractTestNGCucumberTests.java:35)
 at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
 at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
 at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
 at java.base/java.lang.reflect.Method.invoke(Method.java:566)
 at org.testng.internal.invokers.MethodInvocationHelper.invokeMethod(MethodInvocationHelper.java:139)
 at org.testng.internal.invokers.TestInvoker.invokeMethod(TestInvoker.java:664)
 at org.testng.internal.invokers.TestInvoker.invokeTestMethod(TestInvoker.java:228)
 at org.testng.internal.invokers.MethodRunner.runInSequence(MethodRunner.java:63)
 at org.testng.internal.invokers.TestInvoker$MethodInvocationAgent.invoke(TestInvoker.java:961)
 at org.testng.internal.invokers.TestInvoker.invokeTestMethods(TestInvoker.java:201)
 at org.testng.internal.invokers.TestMethodWorker.invokeTestMethods(TestMethodWorker.java:148)
 at org.testng.internal.invokers.TestMethodWorker.run(TestMethodWorker.java:128)
 at java.base/java.util.ArrayList.forEach(ArrayList.java:1541)
 at org.testng.TestRunner.privateRun(TestRunner.java:819)
 at org.testng.TestRunner.run(TestRunner.java:619)
 at org.testng.SuiteRunner.runTest(SuiteRunner.java:443)
 at org.testng.SuiteRunner.runSequentially(SuiteRunner.java:437)
 at org.testng.SuiteRunner.privateRun(SuiteRunner.java:397)
 at org.testng.SuiteRunner.run(SuiteRunner.java:336)
 at org.testng.SuiteRunnerWorker.runSuite(SuiteRunnerWorker.java:52)
DETAILED SECTION -- 17 --
# Step / Hook Details Status Duration
 at org.testng.SuiteRunnerWorker.run(SuiteRunnerWorker.java:95)
 at org.testng.TestNG.runSuitesSequentially(TestNG.java:1301)
 at org.testng.TestNG.runSuitesLocally(TestNG.java:1228)
 at org.testng.TestNG.runSuites(TestNG.java:1134)
 at org.testng.TestNG.run(TestNG.java:1101)
 at org.apache.maven.surefire.testng.TestNGExecutor.run(TestNGExecutor.java:136)
 at org.apache.maven.surefire.testng.TestNGDirectoryTestSuite.executeSingleClass(TestNGDirectoryTestSuite.java:112)
 at org.apache.maven.surefire.testng.TestNGDirectoryTestSuite.execute(TestNGDirectoryTestSuite.java:99)
 at org.apache.maven.surefire.testng.TestNGProvider.invoke(TestNGProvider.java:145)
 at org.apache.maven.surefire.booter.ForkedBooter.runSuitesInProcess(ForkedBooter.java:428)
 at org.apache.maven.surefire.booter.ForkedBooter.execute(ForkedBooter.java:162)
 at org.apache.maven.surefire.booter.ForkedBooter.run(ForkedBooter.java:562)
 at org.apache.maven.surefire.booter.ForkedBooter.main(ForkedBooter.java:548)
Caused by: java.lang.reflect.InvocationTargetException
 at java.base/jdk.internal.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
 at java.base/jdk.internal.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:62)
 at java.base/jdk.internal.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)
 at java.base/java.lang.reflect.Constructor.newInstance(Constructor.java:490)
 at io.cucumber.core.backend.DefaultObjectFactory.cacheNewInstance(DefaultObjectFactory.java:53)
 ... 50 more Caused by: org.openqa.selenium.SessionNotCreatedException: Could not start a new session. Possible causes are invalid
address of the remote server or browser start-up failure. Host info: host: 'fv-az795-342', ip: '10.1.0.8'
 at org.openqa.selenium.remote.RemoteWebDriver.execute(RemoteWebDriver.java:537)
 at org.openqa.selenium.remote.RemoteWebDriver.startSession(RemoteWebDriver.java:233)
 at org.openqa.selenium.remote.RemoteWebDriver.<init>(RemoteWebDriver.java:162)
 at org.openqa.selenium.chromium.ChromiumDriver.<init>(ChromiumDriver.java:114)
 at org.openqa.selenium.chrome.ChromeDriver.<init>(ChromeDriver.java:89)
 at org.openqa.selenium.chrome.ChromeDriver.<init>(ChromeDriver.java:84)
 at org.openqa.selenium.chrome.ChromeDriver.<init>(ChromeDriver.java:73)
 at Utilities.GWD.getDriver(GWD.java:87)
 at Pages.Parent.<init>(Parent.java:24)
 at Pages.LeftNav.<init>(LeftNav.java:10)
 at StepDefinitions._05_DataTableSteps.<init>(_05_DataTableSteps.java:30)
 ... 55 more Caused by: org.openqa.selenium.WebDriverException: Failed waiting for driver server to start. Build info: version: '4.18.1',
revision: 'b1d3319b48' System info: os.name: 'Windows Server 2019', os.arch: 'amd64', os.version: '10.0', java.version: '11.0.8-internal' Driver
info: driver.version: ChromeDriver
 at org.openqa.selenium.remote.service.DriverService.start(DriverService.java:253)
 at org.openqa.selenium.remote.service.DriverCommandExecutor.execute(DriverCommandExecutor.java:117)
 at org.openqa.selenium.remote.RemoteWebDriver.execute(RemoteWebDriver.java:519)
 ... 65 more Caused by: java.util.concurrent.ExecutionException: org.openqa.selenium.WebDriverException: Timed out waiting for driver
server to start. Build info: version: '4.18.1', revision: 'b1d3319b48' System info: os.name: 'Windows Server 2019', os.arch: 'amd64', os.version:
'10.0', java.version: '11.0.8-internal' Driver info: driver.version: unknown
DETAILED SECTION -- 18 --
# Step / Hook Details Status Duration
 at java.base/java.util.concurrent.CompletableFuture.reportGet(CompletableFuture.java:395)
 at java.base/java.util.concurrent.CompletableFuture.get(CompletableFuture.java:2022)
 at org.openqa.selenium.remote.service.DriverService.start(DriverService.java:234)
 ... 67 more Caused by: org.openqa.selenium.WebDriverException: Timed out waiting for driver server to start. Build info: version: '4.18.1',
revision: 'b1d3319b48' System info: os.name: 'Windows Server 2019', os.arch: 'amd64', os.version: '10.0', java.version: '11.0.8-internal' Driver
info: driver.version: unknown
 at org.openqa.selenium.remote.service.DriverService.waitUntilAvailable(DriverService.java:278)
 at org.openqa.selenium.remote.service.DriverService.lambda$start$1(DriverService.java:212)
 at java.base/java.util.concurrent.CompletableFuture$AsyncSupply.run(CompletableFuture.java:1700)
 at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128)
 at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628)
 at java.base/java.lang.Thread.run(Thread.java:834)
Caused by: org.openqa.selenium.net.UrlChecker$TimeoutException: Timed out waiting for [http://localhost:15366/status] to be available after
20000 ms
 at org.openqa.selenium.net.UrlChecker.waitUntilAvailable(UrlChecker.java:94)
 at org.openqa.selenium.remote.service.DriverService.waitUntilAvailable(DriverService.java:274)
 ... 5 more Caused by: java.util.concurrent.TimeoutException
 at java.base/java.util.concurrent.FutureTask.get(FutureTask.java:204)
 at org.openqa.selenium.net.UrlChecker.waitUntilAvailable(UrlChecker.java:91)

`

After a scenario failed, rest of the scenarios failing too:

Given Naviagate to Microfon FAILED 53.883 s

`io.cucumber.core.exception.CucumberException: Failed to instantiate class StepDefinitions._05_DataTableSteps
 at io.cucumber.core.backend.DefaultObjectFactory.cacheNewInstance(DefaultObjectFactory.java:67)
 at io.cucumber.core.backend.DefaultObjectFactory.getInstance(DefaultObjectFactory.java:45)
 at io.cucumber.java.AbstractGlueDefinition.invokeMethod(AbstractGlueDefinition.java:47)
 at io.cucumber.java.JavaStepDefinition.execute(JavaStepDefinition.java:29)
 at io.cucumber.core.runner.CoreStepDefinition.execute(CoreStepDefinition.java:66)
 at io.cucumber.core.runner.PickleStepDefinitionMatch.runStep(PickleStepDefinitionMatch.java:63)
 at io.cucumber.core.runner.ExecutionMode$1.execute(ExecutionMode.java:10)
 at io.cucumber.core.runner.TestStep.executeStep(TestStep.java:84)
 at io.cucumber.core.runner.TestStep.run(TestStep.java:56)
 at io.cucumber.core.runner.PickleStepTestStep.run(PickleStepTestStep.java:51)
 at io.cucumber.core.runner.TestCase.run(TestCase.java:84)
 at io.cucumber.core.runner.Runner.runPickle(Runner.java:75)
 at io.cucumber.testng.TestNGCucumberRunner.lambda$runScenario$1(TestNGCucumberRunner.java:132)
 at io.cucumber.core.runtime.CucumberExecutionContext.lambda$runTestCase$5(CucumberExecutionContext.java:137)
 at io.cucumber.core.runtime.RethrowingThrowableCollector.executeAndThrow(RethrowingThrowableCollector.java:23)
 at io.cucumber.core.runtime.CucumberExecutionContext.runTestCase(CucumberExecutionContext.java:137)
 at io.cucumber.testng.TestNGCucumberRunner.runScenario(TestNGCucumberRunner.java:129)
 at io.cucumber.testng.AbstractTestNGCucumberTests.runScenario(AbstractTestNGCucumberTests.java:35)
DETAILED SECTION -- 22 --
# Step / Hook Details Status Duration
 at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
 at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
 at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
 at java.base/java.lang.reflect.Method.invoke(Method.java:566)
 at org.testng.internal.invokers.MethodInvocationHelper.invokeMethod(MethodInvocationHelper.java:139)
 at org.testng.internal.invokers.TestInvoker.invokeMethod(TestInvoker.java:664)
 at org.testng.internal.invokers.TestInvoker.invokeTestMethod(TestInvoker.java:228)
 at org.testng.internal.invokers.MethodRunner.runInSequence(MethodRunner.java:63)
 at org.testng.internal.invokers.TestInvoker$MethodInvocationAgent.invoke(TestInvoker.java:961)
 at org.testng.internal.invokers.TestInvoker.invokeTestMethods(TestInvoker.java:201)
 at org.testng.internal.invokers.TestMethodWorker.invokeTestMethods(TestMethodWorker.java:148)
 at org.testng.internal.invokers.TestMethodWorker.run(TestMethodWorker.java:128)
 at java.base/java.util.ArrayList.forEach(ArrayList.java:1541)
 at org.testng.TestRunner.privateRun(TestRunner.java:819)
 at org.testng.TestRunner.run(TestRunner.java:619)
 at org.testng.SuiteRunner.runTest(SuiteRunner.java:443)
 at org.testng.SuiteRunner.runSequentially(SuiteRunner.java:437)
 at org.testng.SuiteRunner.privateRun(SuiteRunner.java:397)
 at org.testng.SuiteRunner.run(SuiteRunner.java:336)
 at org.testng.SuiteRunnerWorker.runSuite(SuiteRunnerWorker.java:52)
 at org.testng.SuiteRunnerWorker.run(SuiteRunnerWorker.java:95)
 at org.testng.TestNG.runSuitesSequentially(TestNG.java:1301)
 at org.testng.TestNG.runSuitesLocally(TestNG.java:1228)
 at org.testng.TestNG.runSuites(TestNG.java:1134)
 at org.testng.TestNG.run(TestNG.java:1101)
 at org.apache.maven.surefire.testng.TestNGExecutor.run(TestNGExecutor.java:136)
 at org.apache.maven.surefire.testng.TestNGDirectoryTestSuite.executeSingleClass(TestNGDirectoryTestSuite.java:112)
 at org.apache.maven.surefire.testng.TestNGDirectoryTestSuite.execute(TestNGDirectoryTestSuite.java:99)
 at org.apache.maven.surefire.testng.TestNGProvider.invoke(TestNGProvider.java:145)
 at org.apache.maven.surefire.booter.ForkedBooter.runSuitesInProcess(ForkedBooter.java:428)
 at org.apache.maven.surefire.booter.ForkedBooter.execute(ForkedBooter.java:162)
 at org.apache.maven.surefire.booter.ForkedBooter.run(ForkedBooter.java:562)
 at org.apache.maven.surefire.booter.ForkedBooter.main(ForkedBooter.java:548)
Caused by: java.lang.reflect.InvocationTargetException
 at java.base/jdk.internal.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
 at java.base/jdk.internal.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:62)
 at java.base/jdk.internal.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)
 at java.base/java.lang.reflect.Constructor.newInstance(Constructor.java:490)
 at io.cucumber.core.backend.DefaultObjectFactory.cacheNewInstance(DefaultObjectFactory.java:53)
 ... 50 more Caused by: org.openqa.selenium.SessionNotCreatedException: Could not start a new session. Possible causes are invalid
address of the remote server or browser start-up failure. Host info: host: 'fv-az795-342', ip: '10.1.0.8'
DETAILED SECTION -- 23 --
# Step / Hook Details Status Duration
 at org.openqa.selenium.remote.RemoteWebDriver.execute(RemoteWebDriver.java:537)
 at org.openqa.selenium.remote.RemoteWebDriver.startSession(RemoteWebDriver.java:233)
 at org.openqa.selenium.remote.RemoteWebDriver.<init>(RemoteWebDriver.java:162)
 at org.openqa.selenium.chromium.ChromiumDriver.<init>(ChromiumDriver.java:114)
 at org.openqa.selenium.chrome.ChromeDriver.<init>(ChromeDriver.java:89)
 at org.openqa.selenium.chrome.ChromeDriver.<init>(ChromeDriver.java:84)
 at org.openqa.selenium.chrome.ChromeDriver.<init>(ChromeDriver.java:73)
 at Utilities.GWD.getDriver(GWD.java:87)
 at Pages.Parent.<init>(Parent.java:24)
 at Pages.LeftNav.<init>(LeftNav.java:10)
 at StepDefinitions._05_DataTableSteps.<init>(_05_DataTableSteps.java:30)
 ... 55 more Caused by: org.openqa.selenium.WebDriverException: Timed out waiting for driver server to bind the port. Build info: version:
'4.18.1', revision: 'b1d3319b48' System info: os.name: 'Windows Server 2019', os.arch: 'amd64', os.version: '10.0', java.version: '11.0.8-internal'
Driver info: driver.version: ChromeDriver
 at org.openqa.selenium.remote.service.DriverService.start(DriverService.java:249)
 at org.openqa.selenium.remote.service.DriverCommandExecutor.execute(DriverCommandExecutor.java:117)
 at org.openqa.selenium.remote.RemoteWebDriver.execute(RemoteWebDriver.java:519)

here is the detail of my project:

POM.xml (ı tried almost every possible combinations of dependencies. this is current pom.)

<project xmlns=”http://maven.apache.org/POM/4.0.0″
xmlns:xsi=”http://www.w3.org/2001/XMLSchema-instance”
xsi:schemaLocation=”http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd”>
<modelVersion>4.0.0</modelVersion>

<groupId>org.example</groupId>
<artifactId>microfon-test-automation</artifactId>
<version>1.0-SNAPSHOT</version>

<properties>
    <maven.compiler.source>11</maven.compiler.source>
    <maven.compiler.target>11</maven.compiler.target>
    <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
    <argLine>-Duser.language=en</argLine>
</properties>

<dependencies>

    <dependency>
        <groupId>org.seleniumhq.selenium</groupId>
        <artifactId>selenium-java</artifactId>
        <version>4.23.1</version>
    </dependency>

    <dependency>
        <groupId>io.cucumber</groupId>
        <artifactId>cucumber-java</artifactId>
        <version>7.18.0</version>
        <scope>test</scope>
    </dependency>

    <dependency>
        <groupId>org.testng</groupId>
        <artifactId>testng</artifactId>
        <version>7.10.2</version>
        <scope>test</scope>
    </dependency>

    <dependency>
        <groupId>io.cucumber</groupId>
        <artifactId>cucumber-testng</artifactId>
        <version>7.18.0</version>
        <scope>test</scope>
    </dependency>

    <dependency>
        <groupId>io.github.bonigarcia</groupId>
        <artifactId>webdrivermanager</artifactId>
        <version>5.9.2</version>
    </dependency>

    <dependency>
        <groupId>org.slf4j</groupId>
        <artifactId>slf4j-api</artifactId>
        <version>2.0.13</version>
    </dependency>

    <dependency>
        <groupId>org.slf4j</groupId>
        <artifactId>slf4j-simple</artifactId>
        <version>2.0.13</version>
        <scope>test</scope>
    </dependency>

    <dependency>
        <groupId>tech.grasshopper</groupId>
        <artifactId>extentreports-cucumber7-adapter</artifactId>
        <version>1.10.1</version>
    </dependency>

</dependencies>


<build>
    <plugins>
        <plugin>
            <groupId>org.apache.maven.plugins</groupId>
            <artifactId>maven-surefire-plugin</artifactId>
            <version>3.0.0-M1</version>
            <configuration>

                <includes>
                    <!-- for  run class or classes  **/:bulunduğu lokasyonu bütün klasörlere göre bulabiliyor   -->
                    <include>**/TestRunnerSmoke.java</include>
                </includes>
                <testFailureIgnore>true</testFailureIgnore>
            </configuration>
        </plugin>
    </plugins>
</build>

<profiles>
    <profile>
        <id>Smoke</id>
        <build>
            <plugins>
                <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-compiler-plugin</artifactId>
                <version>3.10.1</version>
                <configuration>
                    <source>11</source>
                    <target>11</target>
                </configuration>
            </plugin>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-surefire-plugin</artifactId>
                <version>3.0.0-M5</version>
                <configuration>

                    <includes>
                        <!-- for  run class or classes  **/:bulunduğu lokasyonu bütün klasörlere göre bulabiliyor   -->
                        <include>**/TestRunnerSmoke.java</include>
                    </includes>

                </configuration>
            </plugin>
        </plugins>
    </build>

</profile>

    </project>

My Driver Settings:

public static WebDriver getDriver() {
        Locale.setDefault(new Locale("EN"));
        System.setProperty("user.language", "EN");

        if (driver == null) {

            Logger.getLogger("").setLevel(Level.SEVERE);
            System.setProperty(org.slf4j.simple.SimpleLogger.DEFAULT_LOG_LEVEL_KEY, "Error");
            System.setProperty(ChromeDriverService.CHROME_DRIVER_SILENT_OUTPUT_PROPERTY, "true");

            WebDriverManager.chromedriver().clearResolutionCache();
            WebDriverManager.chromedriver().clearDriverCache();
          // WebDriverManager.chromedriver().clearDriverCache().setup();  (normally ı use this)
            WebDriverManager.chromedriver().driverVersion("127.0.6533.100").setup();

            if (!runningFromIntelliJ()) {
                ChromeOptions options = new ChromeOptions();
                options.addArguments("--headless", "--no-sandbox", "--disable-dev-shm-usage", "--disable-gpu", "--window-size=1400,2400");
//               options.addArguments("--window-size=1920,1080");
//                options.addArguments("--start-maximized");

//                        System.setProperty("webdriver.chrome.driver", "src/test/resources/drivers/chromedriver.exe");
                driver = new ChromeDriver(options);
            } else {
//                               ChromeOptions options = new ChromeOptions();
//                        options.addArguments("--headless", "--no-sandbox", "--disable-dev-shm-usage", "--disable-gpu", "--window-size=1920,1080");
//                        System.setProperty("webdriver.chrome.driver", "src/test/resources/drivers/chromedriver.exe");
//                options.addArguments("--start-maximized");
//                driver = new ChromeDriver(options); // bu threade bir webdriver atanıyor
                driver = new ChromeDriver();
            }
        }
        return driver;
    }

    public static boolean runningFromIntelliJ() {
        String classPath = System.getProperty("java.class.path");
        return classPath.contains("idea_rt.jar");
    }

    public static void quitDriver() {
        try {
            Thread.sleep(2000);
        } catch (InterruptedException e) {
            throw new RuntimeException(e);
        }

        if (driver != null)  // dolu ise
        {
            driver.quit();
            driver = null;
        }
    }

My Hooks

public class Hooks {
    @Before
    public void before(Scenario senaryo) {
        System.out.println("Senaryo başladı: "+senaryo.getName());
    }

    @After
    public void after(Scenario senaryo) {
        System.out.println("Senaryo bitti Status:"+senaryo.getStatus());

            if (senaryo.isFailed())
            {
                final byte[] byteHali = ((TakesScreenshot) GWD.getDriver()).getScreenshotAs(OutputType.BYTES);
                senaryo.attach(byteHali, "image/png", "screenshot name");
            }
            GWD.quitDriver();
     }
}

My runner class:

@CucumberOptions(
        tags = "@SmokeTest",
        features = {"src/test/java/FeatureFiles"},
        glue = {"StepDefinitions"}
//     , plugin= {"pretty","html:target/site/cucumber-pretty","json:target/cucumber/cucumber.json"}
     , plugin = {"com.aventstack.extentreports.cucumber.adapter.ExtentCucumberAdapter:"}
)
public class TestRunnerSmoke extends AbstractTestNGCucumberTests {

    @AfterClass
    public void writeExtentReport() {
        ExtentService.getInstance().setSystemInfo("Windows User Name", System.getProperty("user.name"));
        ExtentService.getInstance().setSystemInfo("Time Zone", System.getProperty("user.timezone"));
        ExtentService.getInstance().setSystemInfo("User Name", "");
        ExtentService.getInstance().setSystemInfo("Application Name", "");
        ExtentService.getInstance().setSystemInfo("Operating System Info", System.getProperty("os.name"));
        ExtentService.getInstance().setSystemInfo("Department", "QA");
    }
}

1

Trang chủ Giới thiệu Sinh nhật bé trai Sinh nhật bé gái Tổ chức sự kiện Biểu diễn giải trí Dịch vụ khác Trang trí tiệc cưới Tổ chức khai trương Tư vấn dịch vụ Thư viện ảnh Tin tức - sự kiện Liên hệ Chú hề sinh nhật Trang trí YEAR END PARTY công ty Trang trí tất niên cuối năm Trang trí tất niên xu hướng mới nhất Trang trí sinh nhật bé trai Hải Đăng Trang trí sinh nhật bé Khánh Vân Trang trí sinh nhật Bích Ngân Trang trí sinh nhật bé Thanh Trang Thuê ông già Noel phát quà Biểu diễn xiếc khỉ Xiếc quay đĩa Dịch vụ tổ chức sự kiện 5 sao Thông tin về chúng tôi Dịch vụ sinh nhật bé trai Dịch vụ sinh nhật bé gái Sự kiện trọn gói Các tiết mục giải trí Dịch vụ bổ trợ Tiệc cưới sang trọng Dịch vụ khai trương Tư vấn tổ chức sự kiện Hình ảnh sự kiện Cập nhật tin tức Liên hệ ngay Thuê chú hề chuyên nghiệp Tiệc tất niên cho công ty Trang trí tiệc cuối năm Tiệc tất niên độc đáo Sinh nhật bé Hải Đăng Sinh nhật đáng yêu bé Khánh Vân Sinh nhật sang trọng Bích Ngân Tiệc sinh nhật bé Thanh Trang Dịch vụ ông già Noel Xiếc thú vui nhộn Biểu diễn xiếc quay đĩa Dịch vụ tổ chức tiệc uy tín Khám phá dịch vụ của chúng tôi Tiệc sinh nhật cho bé trai Trang trí tiệc cho bé gái Gói sự kiện chuyên nghiệp Chương trình giải trí hấp dẫn Dịch vụ hỗ trợ sự kiện Trang trí tiệc cưới đẹp Khởi đầu thành công với khai trương Chuyên gia tư vấn sự kiện Xem ảnh các sự kiện đẹp Tin mới về sự kiện Kết nối với đội ngũ chuyên gia Chú hề vui nhộn cho tiệc sinh nhật Ý tưởng tiệc cuối năm Tất niên độc đáo Trang trí tiệc hiện đại Tổ chức sinh nhật cho Hải Đăng Sinh nhật độc quyền Khánh Vân Phong cách tiệc Bích Ngân Trang trí tiệc bé Thanh Trang Thuê dịch vụ ông già Noel chuyên nghiệp Xem xiếc khỉ đặc sắc Xiếc quay đĩa thú vị
Trang chủ Giới thiệu Sinh nhật bé trai Sinh nhật bé gái Tổ chức sự kiện Biểu diễn giải trí Dịch vụ khác Trang trí tiệc cưới Tổ chức khai trương Tư vấn dịch vụ Thư viện ảnh Tin tức - sự kiện Liên hệ Chú hề sinh nhật Trang trí YEAR END PARTY công ty Trang trí tất niên cuối năm Trang trí tất niên xu hướng mới nhất Trang trí sinh nhật bé trai Hải Đăng Trang trí sinh nhật bé Khánh Vân Trang trí sinh nhật Bích Ngân Trang trí sinh nhật bé Thanh Trang Thuê ông già Noel phát quà Biểu diễn xiếc khỉ Xiếc quay đĩa
Thiết kế website Thiết kế website Thiết kế website Cách kháng tài khoản quảng cáo Mua bán Fanpage Facebook Dịch vụ SEO Tổ chức sinh nhật