aboutsummaryrefslogtreecommitdiff
path: root/test/transform/resource/before
diff options
context:
space:
mode:
Diffstat (limited to 'test/transform/resource/before')
-rw-r--r--test/transform/resource/before/GetterLazy.java7
-rw-r--r--test/transform/resource/before/GetterLazyEahcToString.java8
-rw-r--r--test/transform/resource/before/GetterLazyInvalid.java27
-rw-r--r--test/transform/resource/before/GetterLazyNative.java28
4 files changed, 70 insertions, 0 deletions
diff --git a/test/transform/resource/before/GetterLazy.java b/test/transform/resource/before/GetterLazy.java
new file mode 100644
index 00000000..51c7a921
--- /dev/null
+++ b/test/transform/resource/before/GetterLazy.java
@@ -0,0 +1,7 @@
+class GetterLazy {
+ static class ValueType {
+ }
+
+ @lombok.Getter(lazy=true)
+ private final ValueType fieldName = new ValueType();
+}
diff --git a/test/transform/resource/before/GetterLazyEahcToString.java b/test/transform/resource/before/GetterLazyEahcToString.java
new file mode 100644
index 00000000..642f8deb
--- /dev/null
+++ b/test/transform/resource/before/GetterLazyEahcToString.java
@@ -0,0 +1,8 @@
+@lombok.EqualsAndHashCode(doNotUseGetters = true)
+@lombok.ToString(doNotUseGetters = true)
+class GetterLazyEahcToString {
+ @lombok.Getter(lazy=true)
+ private final String value = "";
+ @lombok.Getter
+ private final String value2 = "";
+}
diff --git a/test/transform/resource/before/GetterLazyInvalid.java b/test/transform/resource/before/GetterLazyInvalid.java
new file mode 100644
index 00000000..cc9f9501
--- /dev/null
+++ b/test/transform/resource/before/GetterLazyInvalid.java
@@ -0,0 +1,27 @@
+class GetterLazyInvalidNotFinal {
+ @lombok.Getter(lazy=true)
+ private String fieldName = "";
+}
+class GetterLazyInvalidNotPrivate {
+ @lombok.Getter(lazy=true)
+ final String fieldName = "";
+}
+class GetterLazyInvalidNotPrivateFinal {
+ @lombok.Getter(lazy=true)
+ String fieldName = "";
+}
+class GetterLazyInvalidNone {
+ @lombok.Getter(lazy=true, value=lombok.AccessLevel.NONE)
+ private final String fieldName = "";
+}
+@lombok.Getter(lazy = true)
+class GetterLazyInvalidClass {
+ private final String fieldName = "";
+}
+class GetterLazyInvalidNoInit {
+ @lombok.Getter(lazy = true)
+ private final String fieldName;
+ GetterLazyInvalidNoInit() {
+ this.fieldName = "foo";
+ }
+} \ No newline at end of file
diff --git a/test/transform/resource/before/GetterLazyNative.java b/test/transform/resource/before/GetterLazyNative.java
new file mode 100644
index 00000000..9b290bc7
--- /dev/null
+++ b/test/transform/resource/before/GetterLazyNative.java
@@ -0,0 +1,28 @@
+class GetterLazyNative {
+ @lombok.Getter(lazy=true)
+ private final boolean booleanField = true;
+
+ @lombok.Getter(lazy=true)
+ private final byte byteField = 1;
+
+ @lombok.Getter(lazy=true)
+ private final short shortField = 1;
+
+ @lombok.Getter(lazy=true)
+ private final int intField = 1;
+
+ @lombok.Getter(lazy=true)
+ private final long longField = 1;
+
+ @lombok.Getter(lazy=true)
+ private final float floatField = 1.0f;
+
+ @lombok.Getter(lazy=true)
+ private final double doubleField = 1.0;
+
+ @lombok.Getter(lazy=true)
+ private final char charField = '1';
+
+ @lombok.Getter(lazy=true)
+ private final int[] intArrayField = new int[] {1};
+}