Welcome to the Question and Answer site for Software Testing Professionals

You can get your queries resolved from Software Testing Professionals.

Ask a Question

Get answers and give answers to questions from other members.

View All Questions

Get votes and earn points to build your reputation in community.

View Hot Questions

0
Close was called before test could end safely using EndTest.

Open 1 Answers 394 Views
0 1
I am getting below error while executing my tests.

com.relevantcodes.extentreports.ExtentTestInterruptedException: Close was called before test could end safely using EndTest.

I have already removed any .close() sentence and also I tried using report.endTest(test); at the end of the test.

Still, I am facing the same issue.

1 Answer

0
0
In your TestNG suite, use @AfterSuite as below.

@AfterTest
protected void afterSuite() {
    super.getReport().endTest(super.getLogger());
    super.getReport().flush();
}
answered by (200 points)

Your answer

Your name to display (optional):
Privacy: Your email address will only be used for sending these notifications.
Anti-spam verification:
To avoid this verification in future, please log in or register.

We have resolved 1.2k+ Software Testing queries!

Software Testing Board Weekly update

We will send you handpicked questions that you would love to answer.

View previous campaigns.

Top Contributors

...