
|
If you were logged in you would be able to see more operations.
|
|
|
The assertNotNull() method from JUnit seems to be recognized as doing a non-null check.
However, the "Constant conditions & exceptions" inspection does not offer it as a QuickFix (when I'm inside a JUnit test method).
Actually something similar could be offered for all test frameworks supported by IDEA:
- JUnit3: simply call assertNotNull() in test superclass
- JUnit4: insert a call to the (static) method, let code style do a static import if applicable?
- TestNG: similar to JUnit4, perhaps prefer org.testng.Assert#assertNotNull()
|
|
Description
|
The assertNotNull() method from JUnit seems to be recognized as doing a non-null check.
However, the "Constant conditions & exceptions" inspection does not offer it as a QuickFix (when I'm inside a JUnit test method).
Actually something similar could be offered for all test frameworks supported by IDEA:
- JUnit3: simply call assertNotNull() in test superclass
- JUnit4: insert a call to the (static) method, let code style do a static import if applicable?
- TestNG: similar to JUnit4, perhaps prefer org.testng.Assert#assertNotNull()
|
Show » |
| There are no comments yet on this issue.
|
|