mirror of
https://github.com/tiennm99/lombok.git
synced 2026-08-20 22:23:49 +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,11 +1,11 @@
|
||||
import lombok.val;
|
||||
|
||||
public class ValComplex {
|
||||
private ValSimple field = new ValSimple();
|
||||
private String field = "";
|
||||
private static final int CONSTANT = 20;
|
||||
|
||||
public void testReferencingOtherFiles() {
|
||||
val shouldBeString = field.method();
|
||||
public void testComplex() {
|
||||
val shouldBeCharArray = field.toCharArray();
|
||||
val shouldBeInt = CONSTANT;
|
||||
val lock = new Object();
|
||||
synchronized (lock) {
|
||||
@@ -13,10 +13,10 @@ public class ValComplex {
|
||||
val inner = 10;
|
||||
switch (field) {
|
||||
case 5:
|
||||
val shouldBeString2 = shouldBeString;
|
||||
val shouldBeCharArray2 = shouldBeCharArray;
|
||||
val innerInner = inner;
|
||||
}
|
||||
}
|
||||
val shouldBeValSimple = field; //Unshadowing
|
||||
val shouldBeString = field; //Unshadowing
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user