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
In a Java class I have written around 10 @test methods. In this class I have created a object(softAssert) for SoftAssert class. In each method at the end of the code I written softAssert.assertAll();
But this line of code printing the first failed assertion message for all the failed methods.
I want to print separate assertion message for each and every method. could any one help me to overcome this.
The text was updated successfully, but these errors were encountered:
@shivakrishnach31 softAssert object does not clear the list of failed asserts when calling assertAll, so you cannot reuse the same softAssert object in multiple tests. Create a new object at the beginning of every test to fix your problem.
In a Java class I have written around 10 @test methods. In this class I have created a object(softAssert) for SoftAssert class. In each method at the end of the code I written softAssert.assertAll();
But this line of code printing the first failed assertion message for all the failed methods.
I want to print separate assertion message for each and every method. could any one help me to overcome this.
The text was updated successfully, but these errors were encountered: