Failing test case for AvoidThrowingRawExceptionTypes

This commit is contained in:
Juan Martín Sotuyo Dodero
2018-05-12 01:03:33 -03:00
parent 21ee3f76ed
commit 43839bd772

View File

@ -54,6 +54,20 @@ public class PmdTest {
cause = new Throwable();
}
}
]]></code>
</test-code>
<test-code>
<description>False negative when importing another exception</description>
<expected-problems>1</expected-problems>
<code><![CDATA[
import java.io.IOException;
public class Foo {
public void bar() {
throw new Exception();
}
}
]]></code>
</test-code>
</test-data>