-
Notifications
You must be signed in to change notification settings - Fork 9.1k
HADOOP-19618. Replace AssumptionViolatedException with TestAbortedException. #7800
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: trunk
Are you sure you want to change the base?
Conversation
🎊 +1 overall
This message was automatically generated. |
@cnauroth Could you help review this PR? Thank you very much! |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
+1,LGTM @slfan1989
maybe we should create our own exceptions for assumption failures, aborted, timed out and use in our code; they could be subclasses of the JUnit equivalent, but give us a bit more independence in future. |
Description of PR
JIRA: HADOOP-19618. Replace AssumptionViolatedException with TestAbortedException.
In JUnit 4, org.junit.internal.AssumptionViolatedException is used to indicate assumption failure and skip the test. However, AssumptionViolatedException is an implementation in JUnit 4, and in JUnit 5, we can use TestAbortedException to replace AssumptionViolatedException.
TestAbortedException is used to indicate that a test has been aborted, and it can be used to replace AssumptionViolatedException. However, it is not directly related to assumption failure and is more commonly used in situations where the test needs to be aborted during execution.
How was this patch tested?
Junit Test.
For code changes:
LICENSE
,LICENSE-binary
,NOTICE-binary
files?