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
The "return type" of the getStatus() method is a Status type from the io.qameta.allure.model library, and the Status enum in the expression Status.FAILED is also from the io.qameta.allure.model library. This is valid in "Allure TestNG 2.27.0" version and below. - This version and below are working -
However, in version 2.28.0 and above, there is an incompatibility between the return type of getStatus() and the Status enum type. result.getStatus() comes from the model library, while the Status enum comes from the entity library. Therefore, I cannot apply equality between these different types.
The relevant bug is as follows:
Operator '==' cannot be applied to 'io.qameta.allure.model.Status', 'io.qameta.allure.entity.Status'.
Steps to Reproduce
Test Case: Implement Allure Listener with beforeTestStop() Method Override
Steps:
1. Create the "AllureListener" Class:
Define a new class named AllureListener.
2. Override the beforeTestStop() Method:
Inside the AllureListener class, override the method beforeTestStop(). @Override public void beforeTestStop(TestResult result) { // Method implementation here }
3. Add Conditional Logic for Test Status:
Implement the following condition within the overridden beforeTestStop() method:
if (result.getStatus() == Status.FAILED || result.getStatus() == Status.SKIPPED || result.getStatus() == Status.BROKEN) { // Add logic for handling these statuses }
Expected Behaviour
"The return type of the result.getStatus() method should be of the same type as the 'Status' enum."
Screenshots or Additional Context
What Language are you using?
Java
What Framework/Allure Integration you are using?
allure-testng
What version of Allure Integration you are using?
2.28.0
What version of Allure Report you are using?
2.28.0
Code of Conduct
I agree to follow this project's Code of Conduct
The text was updated successfully, but these errors were encountered:
Describe the Bug
What happened?
if (result.getStatus() == Status.FAILED {}
The "return type" of the getStatus() method is a Status type from the io.qameta.allure.model library, and the Status enum in the expression Status.FAILED is also from the io.qameta.allure.model library. This is valid in "Allure TestNG 2.27.0" version and below. - This version and below are working -
However, in version 2.28.0 and above, there is an incompatibility between the return type of getStatus() and the Status enum type.
result.getStatus()
comes from the model library, while theStatus
enum comes from the entity library. Therefore, I cannot apply equality between these different types.The relevant bug is as follows:
Steps to Reproduce
Test Case: Implement Allure Listener with beforeTestStop() Method Override
Steps:
1. Create the "AllureListener" Class:
Define a new class named AllureListener.
2. Override the beforeTestStop() Method:
Inside the AllureListener class, override the method beforeTestStop().
@Override public void beforeTestStop(TestResult result) { // Method implementation here }
3. Add Conditional Logic for Test Status:
if (result.getStatus() == Status.FAILED || result.getStatus() == Status.SKIPPED || result.getStatus() == Status.BROKEN) { // Add logic for handling these statuses }
Expected Behaviour
"The return type of the result.getStatus() method should be of the same type as the 'Status' enum."
Screenshots or Additional Context
What Language are you using?
Java
What Framework/Allure Integration you are using?
allure-testng
What version of Allure Integration you are using?
2.28.0
What version of Allure Report you are using?
2.28.0
Code of Conduct
The text was updated successfully, but these errors were encountered: