aboutsummaryrefslogtreecommitdiff
path: root/test/transform
diff options
context:
space:
mode:
Diffstat (limited to 'test/transform')
-rw-r--r--test/transform/resource/after-delombok/FieldNameConstantsBasic.java8
-rw-r--r--test/transform/resource/after-delombok/FieldNameConstantsConfigKeys.java7
-rw-r--r--test/transform/resource/after-delombok/FieldNameConstantsEnum.java10
-rw-r--r--test/transform/resource/after-delombok/FieldNameConstantsWeird.java6
-rw-r--r--test/transform/resource/after-ecj/FieldNameConstantsBasic.java18
-rw-r--r--test/transform/resource/after-ecj/FieldNameConstantsConfigKeys.java13
-rw-r--r--test/transform/resource/after-ecj/FieldNameConstantsEnum.java23
-rw-r--r--test/transform/resource/after-ecj/FieldNameConstantsWeird.java13
-rw-r--r--test/transform/resource/before/FieldNameConstantsBasic.java4
-rw-r--r--test/transform/resource/before/FieldNameConstantsConfigKeys.java3
-rw-r--r--test/transform/resource/before/FieldNameConstantsEnum.java13
-rw-r--r--test/transform/resource/before/FieldNameConstantsWeird.java12
-rw-r--r--test/transform/resource/messages-delombok/FieldNameConstantsWeird.java.messages1
-rw-r--r--test/transform/resource/messages-ecj/FieldNameConstantsWeird.java.messages1
14 files changed, 82 insertions, 50 deletions
diff --git a/test/transform/resource/after-delombok/FieldNameConstantsBasic.java b/test/transform/resource/after-delombok/FieldNameConstantsBasic.java
index 4e547aa5..8be45d2b 100644
--- a/test/transform/resource/after-delombok/FieldNameConstantsBasic.java
+++ b/test/transform/resource/after-delombok/FieldNameConstantsBasic.java
@@ -1,8 +1,12 @@
public class FieldNameConstantsBasic {
- protected static final java.lang.String FIELD_I_AM_A_DVD_PLAYER = "iAmADvdPlayer";
- public static final java.lang.String FIELD_BUT_PRINT_ME_PLEASE = "butPrintMePlease";
String iAmADvdPlayer;
int $skipMe;
static double skipMeToo;
+ int andMe;
String butPrintMePlease;
+ @java.lang.SuppressWarnings("all")
+ static final class Fields {
+ public static final java.lang.String butPrintMePlease = "butPrintMePlease";
+ public static final java.lang.String iAmADvdPlayer = "iAmADvdPlayer";
+ }
}
diff --git a/test/transform/resource/after-delombok/FieldNameConstantsConfigKeys.java b/test/transform/resource/after-delombok/FieldNameConstantsConfigKeys.java
index c71b9264..4c2a53e3 100644
--- a/test/transform/resource/after-delombok/FieldNameConstantsConfigKeys.java
+++ b/test/transform/resource/after-delombok/FieldNameConstantsConfigKeys.java
@@ -1,4 +1,7 @@
public class FieldNameConstantsConfigKeys {
- public static final java.lang.String I_AM_A_DVD_PLAYER_SFX = "iAmADvdPlayer";
String iAmADvdPlayer;
-}
+ @java.lang.SuppressWarnings("all")
+ public static final class Foobar {
+ public static final java.lang.String iAmADvdPlayer = "iAmADvdPlayer";
+ }
+} \ No newline at end of file
diff --git a/test/transform/resource/after-delombok/FieldNameConstantsEnum.java b/test/transform/resource/after-delombok/FieldNameConstantsEnum.java
new file mode 100644
index 00000000..c3fbf0c2
--- /dev/null
+++ b/test/transform/resource/after-delombok/FieldNameConstantsEnum.java
@@ -0,0 +1,10 @@
+public class FieldNameConstantsEnum {
+ String iAmADvdPlayer;
+ int $dontSkipMe;
+ static double alsoDontSkipMe;
+ int butSkipMe;
+ @java.lang.SuppressWarnings("all")
+ public enum TypeTest {
+ iAmADvdPlayer, $dontSkipMe, alsoDontSkipMe;
+ }
+}
diff --git a/test/transform/resource/after-delombok/FieldNameConstantsWeird.java b/test/transform/resource/after-delombok/FieldNameConstantsWeird.java
deleted file mode 100644
index 6940f628..00000000
--- a/test/transform/resource/after-delombok/FieldNameConstantsWeird.java
+++ /dev/null
@@ -1,6 +0,0 @@
-public class FieldNameConstantsWeird {
- public static final java.lang.String FIELD_AZ = "A";
- String iAmADvdPlayer;
- String X;
- String A;
-}
diff --git a/test/transform/resource/after-ecj/FieldNameConstantsBasic.java b/test/transform/resource/after-ecj/FieldNameConstantsBasic.java
index f77203ba..674dd602 100644
--- a/test/transform/resource/after-ecj/FieldNameConstantsBasic.java
+++ b/test/transform/resource/after-ecj/FieldNameConstantsBasic.java
@@ -1,15 +1,23 @@
import lombok.experimental.FieldNameConstants;
import lombok.AccessLevel;
-public @FieldNameConstants class FieldNameConstantsBasic {
- public static final java.lang.String FIELD_BUT_PRINT_ME_PLEASE = "butPrintMePlease";
- protected static final java.lang.String FIELD_I_AM_A_DVD_PLAYER = "iAmADvdPlayer";
- @FieldNameConstants(level = AccessLevel.PROTECTED) String iAmADvdPlayer;
+public @FieldNameConstants(level = AccessLevel.PACKAGE) class FieldNameConstantsBasic {
+ static final @java.lang.SuppressWarnings("all") class Fields {
+ public static final java.lang.String butPrintMePlease = "butPrintMePlease";
+ public static final java.lang.String iAmADvdPlayer = "iAmADvdPlayer";
+ <clinit>() {
+ }
+ private @java.lang.SuppressWarnings("all") Fields() {
+ super();
+ }
+ }
+ String iAmADvdPlayer;
int $skipMe;
static double skipMeToo;
+ @FieldNameConstants.Exclude int andMe;
String butPrintMePlease;
<clinit>() {
}
public FieldNameConstantsBasic() {
super();
}
-}
+} \ No newline at end of file
diff --git a/test/transform/resource/after-ecj/FieldNameConstantsConfigKeys.java b/test/transform/resource/after-ecj/FieldNameConstantsConfigKeys.java
index 44629ee5..7eb97364 100644
--- a/test/transform/resource/after-ecj/FieldNameConstantsConfigKeys.java
+++ b/test/transform/resource/after-ecj/FieldNameConstantsConfigKeys.java
@@ -1,9 +1,14 @@
public @lombok.experimental.FieldNameConstants class FieldNameConstantsConfigKeys {
- public static final java.lang.String I_AM_A_DVD_PLAYER_SFX = "iAmADvdPlayer";
- String iAmADvdPlayer;
- <clinit>() {
+ public static final @java.lang.SuppressWarnings("all") class Foobar {
+ public static final java.lang.String iAmADvdPlayer = "iAmADvdPlayer";
+ <clinit>() {
+ }
+ private @java.lang.SuppressWarnings("all") Foobar() {
+ super();
+ }
}
+ String iAmADvdPlayer;
public FieldNameConstantsConfigKeys() {
super();
}
-}
+} \ No newline at end of file
diff --git a/test/transform/resource/after-ecj/FieldNameConstantsEnum.java b/test/transform/resource/after-ecj/FieldNameConstantsEnum.java
new file mode 100644
index 00000000..053a6e7a
--- /dev/null
+++ b/test/transform/resource/after-ecj/FieldNameConstantsEnum.java
@@ -0,0 +1,23 @@
+import lombok.experimental.FieldNameConstants;
+import lombok.AccessLevel;
+public @FieldNameConstants(onlyExplicitlyIncluded = true,asEnum = true,innerTypeName = "TypeTest") class FieldNameConstantsEnum {
+ public @java.lang.SuppressWarnings("all") enum TypeTest {
+ iAmADvdPlayer(),
+ $dontSkipMe(),
+ alsoDontSkipMe(),
+ private @java.lang.SuppressWarnings("all") TypeTest() {
+ super();
+ }
+ <clinit>() {
+ }
+ }
+ @FieldNameConstants.Include String iAmADvdPlayer;
+ @FieldNameConstants.Include int $dontSkipMe;
+ static @FieldNameConstants.Include double alsoDontSkipMe;
+ int butSkipMe;
+ <clinit>() {
+ }
+ public FieldNameConstantsEnum() {
+ super();
+ }
+} \ No newline at end of file
diff --git a/test/transform/resource/after-ecj/FieldNameConstantsWeird.java b/test/transform/resource/after-ecj/FieldNameConstantsWeird.java
deleted file mode 100644
index 9958f664..00000000
--- a/test/transform/resource/after-ecj/FieldNameConstantsWeird.java
+++ /dev/null
@@ -1,13 +0,0 @@
-import lombok.experimental.FieldNameConstants;
-import lombok.AccessLevel;
-public @FieldNameConstants class FieldNameConstantsWeird {
- public static final java.lang.String FIELD_AZ = "A";
- @FieldNameConstants(level = AccessLevel.NONE) String iAmADvdPlayer;
- @FieldNameConstants(prefix = "") String X;
- @FieldNameConstants(suffix = "Z") String A;
- <clinit>() {
- }
- public FieldNameConstantsWeird() {
- super();
- }
-}
diff --git a/test/transform/resource/before/FieldNameConstantsBasic.java b/test/transform/resource/before/FieldNameConstantsBasic.java
index 1bc15d84..2842dea3 100644
--- a/test/transform/resource/before/FieldNameConstantsBasic.java
+++ b/test/transform/resource/before/FieldNameConstantsBasic.java
@@ -1,11 +1,11 @@
import lombok.experimental.FieldNameConstants;
import lombok.AccessLevel;
-@FieldNameConstants
+@FieldNameConstants(level = AccessLevel.PACKAGE)
public class FieldNameConstantsBasic {
- @FieldNameConstants(level = AccessLevel.PROTECTED)
String iAmADvdPlayer;
int $skipMe;
static double skipMeToo;
+ @FieldNameConstants.Exclude int andMe;
String butPrintMePlease;
}
diff --git a/test/transform/resource/before/FieldNameConstantsConfigKeys.java b/test/transform/resource/before/FieldNameConstantsConfigKeys.java
index ab8e3091..5595222c 100644
--- a/test/transform/resource/before/FieldNameConstantsConfigKeys.java
+++ b/test/transform/resource/before/FieldNameConstantsConfigKeys.java
@@ -1,5 +1,4 @@
-//CONF: lombok.fieldNameConstants.prefix =
-//CONF: lombok.fieldNameConstants.suffix = _SFX
+//CONF: lombok.fieldNameConstants.innerTypeName = Foobar
@lombok.experimental.FieldNameConstants
public class FieldNameConstantsConfigKeys {
diff --git a/test/transform/resource/before/FieldNameConstantsEnum.java b/test/transform/resource/before/FieldNameConstantsEnum.java
new file mode 100644
index 00000000..d56bb280
--- /dev/null
+++ b/test/transform/resource/before/FieldNameConstantsEnum.java
@@ -0,0 +1,13 @@
+import lombok.experimental.FieldNameConstants;
+import lombok.AccessLevel;
+
+@FieldNameConstants(onlyExplicitlyIncluded = true, asEnum = true, innerTypeName = "TypeTest")
+public class FieldNameConstantsEnum {
+ @FieldNameConstants.Include
+ String iAmADvdPlayer;
+ @FieldNameConstants.Include
+ int $dontSkipMe;
+ @FieldNameConstants.Include
+ static double alsoDontSkipMe;
+ int butSkipMe;
+}
diff --git a/test/transform/resource/before/FieldNameConstantsWeird.java b/test/transform/resource/before/FieldNameConstantsWeird.java
deleted file mode 100644
index 74ec299a..00000000
--- a/test/transform/resource/before/FieldNameConstantsWeird.java
+++ /dev/null
@@ -1,12 +0,0 @@
-import lombok.experimental.FieldNameConstants;
-import lombok.AccessLevel;
-
-@FieldNameConstants
-public class FieldNameConstantsWeird {
- @FieldNameConstants(level = AccessLevel.NONE)
- String iAmADvdPlayer;
- @FieldNameConstants(prefix = "")
- String X;
- @FieldNameConstants(suffix = "Z")
- String A;
-}
diff --git a/test/transform/resource/messages-delombok/FieldNameConstantsWeird.java.messages b/test/transform/resource/messages-delombok/FieldNameConstantsWeird.java.messages
deleted file mode 100644
index 02a38d58..00000000
--- a/test/transform/resource/messages-delombok/FieldNameConstantsWeird.java.messages
+++ /dev/null
@@ -1 +0,0 @@
-9 Not generating constant for this field: The name of the constant would be equal to the name of this field.
diff --git a/test/transform/resource/messages-ecj/FieldNameConstantsWeird.java.messages b/test/transform/resource/messages-ecj/FieldNameConstantsWeird.java.messages
deleted file mode 100644
index 02a38d58..00000000
--- a/test/transform/resource/messages-ecj/FieldNameConstantsWeird.java.messages
+++ /dev/null
@@ -1 +0,0 @@
-9 Not generating constant for this field: The name of the constant would be equal to the name of this field.