Modifier and Type | Method and Description |
---|---|
HintTest.AppliedFix |
applyFix()
Applies the only fix of the current warning.
|
HintTest.AppliedFix |
applyFix(String fix)
Applies the specified fix of the current warning.
|
HintTest.HintWarning |
assertFixes(String... expectedFixes)
Verifies that the current warning provides the given fixes.
|
HintTest.HintWarning |
assertFixesNotPresent(String... bannedFixes)
Verifies that the current warning provides the given fixes.
|
public HintTest.AppliedFix applyFix() throws Exception
HintTest.run(java.lang.Class)
or HintTest.HintWarning.applyFix()
cannot be run in the future on any object that follows the chain from the same invocation of HintTest.create()
.AssertionError
- if there is not one fix for the given ErrorDescription
Exception
public HintTest.AppliedFix applyFix(String fix) throws Exception
HintTest.run(java.lang.Class)
or HintTest.HintWarning.applyFix()
cannot be run in the future on any object that follows the chain from the same invocation of HintTest.create()
.fix
- Fix.getText()
result of the required fixAssertionError
- if the fix cannot be foundException
public HintTest.HintWarning assertFixes(String... expectedFixes) throws Exception
expectedFixes
- the Fix.getText()
of the expected fixesAssertionError
- if the expected fixes do not match the provided fixesException
public HintTest.HintWarning assertFixesNotPresent(String... bannedFixes) throws Exception
bannedFixes
- the Fix.getText()
of the expected fixesAssertionError
- if the expected fixes do not match the provided fixesException