From b081e6c968817fe5df57b359ad04fc3f4580d38c Mon Sep 17 00:00:00 2001 From: Roel Spilker Date: Mon, 23 Apr 2018 21:00:01 +0200 Subject: Allow onMethod and onParam in @Getter and @Setter if it is put on a type --- .../resource/after-delombok/GetterOnMethodErrors.java | 9 --------- .../resource/after-delombok/GetterOnMethodOnType.java | 14 ++++++++++++++ .../transform/resource/after-ecj/GetterOnMethodErrors.java | 14 -------------- .../transform/resource/after-ecj/GetterOnMethodOnType.java | 13 +++++++++++++ test/transform/resource/before/GetterOnMethodErrors.java | 6 ------ test/transform/resource/before/GetterOnMethodOnType.java | 5 +++++ .../messages-delombok/GetterOnMethodErrors.java.messages | 1 - .../messages-ecj/GetterOnMethodErrors.java.messages | 1 - 8 files changed, 32 insertions(+), 31 deletions(-) delete mode 100644 test/transform/resource/after-delombok/GetterOnMethodErrors.java create mode 100644 test/transform/resource/after-delombok/GetterOnMethodOnType.java delete mode 100644 test/transform/resource/after-ecj/GetterOnMethodErrors.java create mode 100644 test/transform/resource/after-ecj/GetterOnMethodOnType.java delete mode 100644 test/transform/resource/before/GetterOnMethodErrors.java create mode 100644 test/transform/resource/before/GetterOnMethodOnType.java delete mode 100644 test/transform/resource/messages-delombok/GetterOnMethodErrors.java.messages delete mode 100644 test/transform/resource/messages-ecj/GetterOnMethodErrors.java.messages (limited to 'test') diff --git a/test/transform/resource/after-delombok/GetterOnMethodErrors.java b/test/transform/resource/after-delombok/GetterOnMethodErrors.java deleted file mode 100644 index a69966ec..00000000 --- a/test/transform/resource/after-delombok/GetterOnMethodErrors.java +++ /dev/null @@ -1,9 +0,0 @@ -class PlaceFillerToMakeSurePositionIsRelevant { -} -class GetterOnMethodErrors { - private int test; - @java.lang.SuppressWarnings("all") - public int getTest() { - return this.test; - } -} diff --git a/test/transform/resource/after-delombok/GetterOnMethodOnType.java b/test/transform/resource/after-delombok/GetterOnMethodOnType.java new file mode 100644 index 00000000..625909c1 --- /dev/null +++ b/test/transform/resource/after-delombok/GetterOnMethodOnType.java @@ -0,0 +1,14 @@ +class GetterOnMethodOnType { + private int test; + private String name; + @Deprecated + @java.lang.SuppressWarnings("all") + public int getTest() { + return this.test; + } + @Deprecated + @java.lang.SuppressWarnings("all") + public String getName() { + return this.name; + } +} diff --git a/test/transform/resource/after-ecj/GetterOnMethodErrors.java b/test/transform/resource/after-ecj/GetterOnMethodErrors.java deleted file mode 100644 index 16c625b5..00000000 --- a/test/transform/resource/after-ecj/GetterOnMethodErrors.java +++ /dev/null @@ -1,14 +0,0 @@ -class PlaceFillerToMakeSurePositionIsRelevant { - PlaceFillerToMakeSurePositionIsRelevant() { - super(); - } -} -@lombok.Getter() class GetterOnMethodErrors { - private int test; - GetterOnMethodErrors() { - super(); - } - public @java.lang.SuppressWarnings("all") int getTest() { - return this.test; - } -} \ No newline at end of file diff --git a/test/transform/resource/after-ecj/GetterOnMethodOnType.java b/test/transform/resource/after-ecj/GetterOnMethodOnType.java new file mode 100644 index 00000000..2b39abf2 --- /dev/null +++ b/test/transform/resource/after-ecj/GetterOnMethodOnType.java @@ -0,0 +1,13 @@ +@lombok.Getter() class GetterOnMethodOnType { + private int test; + private String name; + GetterOnMethodOnType() { + super(); + } + public @Deprecated @java.lang.SuppressWarnings("all") int getTest() { + return this.test; + } + public @Deprecated @java.lang.SuppressWarnings("all") String getName() { + return this.name; + } +} \ No newline at end of file diff --git a/test/transform/resource/before/GetterOnMethodErrors.java b/test/transform/resource/before/GetterOnMethodErrors.java deleted file mode 100644 index ec4704f0..00000000 --- a/test/transform/resource/before/GetterOnMethodErrors.java +++ /dev/null @@ -1,6 +0,0 @@ -class PlaceFillerToMakeSurePositionIsRelevant { -} -@lombok.Getter(onMethod=@__(@Deprecated)) -class GetterOnMethodErrors { - private int test; -} diff --git a/test/transform/resource/before/GetterOnMethodOnType.java b/test/transform/resource/before/GetterOnMethodOnType.java new file mode 100644 index 00000000..296ebcc4 --- /dev/null +++ b/test/transform/resource/before/GetterOnMethodOnType.java @@ -0,0 +1,5 @@ +@lombok.Getter(onMethod=@__(@Deprecated)) +class GetterOnMethodOnType { + private int test; + private String name; +} diff --git a/test/transform/resource/messages-delombok/GetterOnMethodErrors.java.messages b/test/transform/resource/messages-delombok/GetterOnMethodErrors.java.messages deleted file mode 100644 index 26c30298..00000000 --- a/test/transform/resource/messages-delombok/GetterOnMethodErrors.java.messages +++ /dev/null @@ -1 +0,0 @@ -3 'onMethod' is not supported for @Getter on a type. \ No newline at end of file diff --git a/test/transform/resource/messages-ecj/GetterOnMethodErrors.java.messages b/test/transform/resource/messages-ecj/GetterOnMethodErrors.java.messages deleted file mode 100644 index 26c30298..00000000 --- a/test/transform/resource/messages-ecj/GetterOnMethodErrors.java.messages +++ /dev/null @@ -1 +0,0 @@ -3 'onMethod' is not supported for @Getter on a type. \ No newline at end of file -- cgit