mirror of
https://github.com/tiennm99/lombok.git
synced 2026-10-14 02:16:18 +00:00
More test files, test files updated to be valid java, and ecj test now goes through the complete compile process. This means val and @Delegate testing is now enabled.
TODO: Update -eclipse tests.
This commit is contained in:
1 parent
5e9e16a6b9
commit
06581537f2
55 files changed
+691
-132
No files matched your search
@@ -1 +1,39 @@
|
||||
//ignore
|
||||
import lombok.val;
|
||||
public class ValLessSimple {
|
||||
private short field2 = 5;
|
||||
{
|
||||
System.out.println("Hello");
|
||||
final @val int z = 20;
|
||||
final @val int x = 10;
|
||||
final @val int a = z;
|
||||
final @val short y = field2;
|
||||
}
|
||||
private String field = "field";
|
||||
public ValLessSimple() {
|
||||
super();
|
||||
}
|
||||
private String method() {
|
||||
return "method";
|
||||
}
|
||||
private double method2() {
|
||||
return 2.0;
|
||||
}
|
||||
private void testVal(String param) {
|
||||
final @val java.lang.String fieldV = field;
|
||||
final @val int a = 10;
|
||||
final @val int b = 20;
|
||||
{
|
||||
final @val java.lang.String methodV = method();
|
||||
final @val java.lang.String foo = (fieldV + methodV);
|
||||
}
|
||||
}
|
||||
private void testValInCatchBlock() {
|
||||
try
|
||||
{
|
||||
final @val int x = (1 / 0);
|
||||
}
|
||||
catch (ArithmeticException e) {
|
||||
final @val int y = 0;
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user