mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-08-17 21:15:58 +07:00
24 lines
439 B
Java
24 lines
439 B
Java
import org.jetbrains.annotations.NotNull;
|
|
import org.junit.Assert;
|
|
|
|
class Test {
|
|
|
|
public static void foo() {
|
|
String result = null;
|
|
try {
|
|
result = createString();
|
|
}
|
|
catch (Exception e) {
|
|
Assert.fail();
|
|
}
|
|
finally {
|
|
if (result == null) {
|
|
System.out.println("Analysis failed!");
|
|
}
|
|
}
|
|
}
|
|
|
|
private static @NotNull String createString() {
|
|
throw new NullPointerException();
|
|
}
|
|
} |