From 11a83f854ccce157f3e7c8700bc2a369239945aa Mon Sep 17 00:00:00 2001 From: Sam Judd Date: Wed, 25 Apr 2018 10:27:31 -0700 Subject: [PATCH] Update annotation tests to support addListener method. --- .../resources/EmptyAppGlideModuleTest/GlideRequest.java | 7 +++++++ .../MemoizeStaticMethod/GlideRequest.java | 7 +++++++ .../OverrideExtend/GlideRequest.java | 7 +++++++ .../OverrideExtendMultipleArguments/GlideRequest.java | 7 +++++++ .../OverrideReplace/GlideRequest.java | 7 +++++++ .../SkipStaticMethod/GlideRequest.java | 7 +++++++ .../StaticMethodName/GlideRequest.java | 7 +++++++ .../GlideExtensionWithOptionTest/GlideRequest.java | 7 +++++++ .../MemoizeStaticMethod/GlideRequest.java | 7 +++++++ .../OverrideExtend/GlideRequest.java | 7 +++++++ .../OverrideReplace/GlideRequest.java | 7 +++++++ .../SkipStaticMethod/GlideRequest.java | 7 +++++++ .../StaticMethodName/GlideRequest.java | 7 +++++++ .../LegacyGlideExtensionWithOptionTest/GlideRequest.java | 7 +++++++ 14 files changed, 98 insertions(+) diff --git a/annotation/compiler/test/src/test/resources/EmptyAppGlideModuleTest/GlideRequest.java b/annotation/compiler/test/src/test/resources/EmptyAppGlideModuleTest/GlideRequest.java index d683d1983c..9536fe2304 100644 --- a/annotation/compiler/test/src/test/resources/EmptyAppGlideModuleTest/GlideRequest.java +++ b/annotation/compiler/test/src/test/resources/EmptyAppGlideModuleTest/GlideRequest.java @@ -670,6 +670,13 @@ public GlideRequest listener(@Nullable RequestListener) super.listener(listener); } + @Override + @NonNull + @CheckResult + public GlideRequest addListener(@Nullable RequestListener listener) { + return (GlideRequest) super.addListener(listener); + } + @Override @NonNull public GlideRequest error(@Nullable RequestBuilder builder) { diff --git a/annotation/compiler/test/src/test/resources/GlideExtensionOptionsTest/MemoizeStaticMethod/GlideRequest.java b/annotation/compiler/test/src/test/resources/GlideExtensionOptionsTest/MemoizeStaticMethod/GlideRequest.java index c9124e93b6..f0377a0a7c 100644 --- a/annotation/compiler/test/src/test/resources/GlideExtensionOptionsTest/MemoizeStaticMethod/GlideRequest.java +++ b/annotation/compiler/test/src/test/resources/GlideExtensionOptionsTest/MemoizeStaticMethod/GlideRequest.java @@ -684,6 +684,13 @@ public GlideRequest listener(@Nullable RequestListener) super.listener(listener); } + @Override + @NonNull + @CheckResult + public GlideRequest addListener(@Nullable RequestListener listener) { + return (GlideRequest) super.addListener(listener); + } + @Override @NonNull public GlideRequest error(@Nullable RequestBuilder builder) { diff --git a/annotation/compiler/test/src/test/resources/GlideExtensionOptionsTest/OverrideExtend/GlideRequest.java b/annotation/compiler/test/src/test/resources/GlideExtensionOptionsTest/OverrideExtend/GlideRequest.java index d47ee27402..ee391f551e 100644 --- a/annotation/compiler/test/src/test/resources/GlideExtensionOptionsTest/OverrideExtend/GlideRequest.java +++ b/annotation/compiler/test/src/test/resources/GlideExtensionOptionsTest/OverrideExtend/GlideRequest.java @@ -670,6 +670,13 @@ public GlideRequest listener(@Nullable RequestListener) super.listener(listener); } + @Override + @NonNull + @CheckResult + public GlideRequest addListener(@Nullable RequestListener listener) { + return (GlideRequest) super.addListener(listener); + } + @Override @NonNull public GlideRequest error(@Nullable RequestBuilder builder) { diff --git a/annotation/compiler/test/src/test/resources/GlideExtensionOptionsTest/OverrideExtendMultipleArguments/GlideRequest.java b/annotation/compiler/test/src/test/resources/GlideExtensionOptionsTest/OverrideExtendMultipleArguments/GlideRequest.java index b6d3f48db4..e6e2e53801 100644 --- a/annotation/compiler/test/src/test/resources/GlideExtensionOptionsTest/OverrideExtendMultipleArguments/GlideRequest.java +++ b/annotation/compiler/test/src/test/resources/GlideExtensionOptionsTest/OverrideExtendMultipleArguments/GlideRequest.java @@ -670,6 +670,13 @@ public GlideRequest listener(@Nullable RequestListener) super.listener(listener); } + @Override + @NonNull + @CheckResult + public GlideRequest addListener(@Nullable RequestListener listener) { + return (GlideRequest) super.addListener(listener); + } + @Override @NonNull public GlideRequest error(@Nullable RequestBuilder builder) { diff --git a/annotation/compiler/test/src/test/resources/GlideExtensionOptionsTest/OverrideReplace/GlideRequest.java b/annotation/compiler/test/src/test/resources/GlideExtensionOptionsTest/OverrideReplace/GlideRequest.java index d47ee27402..ee391f551e 100644 --- a/annotation/compiler/test/src/test/resources/GlideExtensionOptionsTest/OverrideReplace/GlideRequest.java +++ b/annotation/compiler/test/src/test/resources/GlideExtensionOptionsTest/OverrideReplace/GlideRequest.java @@ -670,6 +670,13 @@ public GlideRequest listener(@Nullable RequestListener) super.listener(listener); } + @Override + @NonNull + @CheckResult + public GlideRequest addListener(@Nullable RequestListener listener) { + return (GlideRequest) super.addListener(listener); + } + @Override @NonNull public GlideRequest error(@Nullable RequestBuilder builder) { diff --git a/annotation/compiler/test/src/test/resources/GlideExtensionOptionsTest/SkipStaticMethod/GlideRequest.java b/annotation/compiler/test/src/test/resources/GlideExtensionOptionsTest/SkipStaticMethod/GlideRequest.java index c9124e93b6..f0377a0a7c 100644 --- a/annotation/compiler/test/src/test/resources/GlideExtensionOptionsTest/SkipStaticMethod/GlideRequest.java +++ b/annotation/compiler/test/src/test/resources/GlideExtensionOptionsTest/SkipStaticMethod/GlideRequest.java @@ -684,6 +684,13 @@ public GlideRequest listener(@Nullable RequestListener) super.listener(listener); } + @Override + @NonNull + @CheckResult + public GlideRequest addListener(@Nullable RequestListener listener) { + return (GlideRequest) super.addListener(listener); + } + @Override @NonNull public GlideRequest error(@Nullable RequestBuilder builder) { diff --git a/annotation/compiler/test/src/test/resources/GlideExtensionOptionsTest/StaticMethodName/GlideRequest.java b/annotation/compiler/test/src/test/resources/GlideExtensionOptionsTest/StaticMethodName/GlideRequest.java index c9124e93b6..f0377a0a7c 100644 --- a/annotation/compiler/test/src/test/resources/GlideExtensionOptionsTest/StaticMethodName/GlideRequest.java +++ b/annotation/compiler/test/src/test/resources/GlideExtensionOptionsTest/StaticMethodName/GlideRequest.java @@ -684,6 +684,13 @@ public GlideRequest listener(@Nullable RequestListener) super.listener(listener); } + @Override + @NonNull + @CheckResult + public GlideRequest addListener(@Nullable RequestListener listener) { + return (GlideRequest) super.addListener(listener); + } + @Override @NonNull public GlideRequest error(@Nullable RequestBuilder builder) { diff --git a/annotation/compiler/test/src/test/resources/GlideExtensionWithOptionTest/GlideRequest.java b/annotation/compiler/test/src/test/resources/GlideExtensionWithOptionTest/GlideRequest.java index b453136b6e..05b6b7d5c0 100644 --- a/annotation/compiler/test/src/test/resources/GlideExtensionWithOptionTest/GlideRequest.java +++ b/annotation/compiler/test/src/test/resources/GlideExtensionWithOptionTest/GlideRequest.java @@ -684,6 +684,13 @@ public GlideRequest listener(@Nullable RequestListener) super.listener(listener); } + @Override + @NonNull + @CheckResult + public GlideRequest addListener(@Nullable RequestListener listener) { + return (GlideRequest) super.addListener(listener); + } + @Override @NonNull public GlideRequest error(@Nullable RequestBuilder builder) { diff --git a/annotation/compiler/test/src/test/resources/LegacyGlideExtensionOptionsTest/MemoizeStaticMethod/GlideRequest.java b/annotation/compiler/test/src/test/resources/LegacyGlideExtensionOptionsTest/MemoizeStaticMethod/GlideRequest.java index c9124e93b6..f0377a0a7c 100644 --- a/annotation/compiler/test/src/test/resources/LegacyGlideExtensionOptionsTest/MemoizeStaticMethod/GlideRequest.java +++ b/annotation/compiler/test/src/test/resources/LegacyGlideExtensionOptionsTest/MemoizeStaticMethod/GlideRequest.java @@ -684,6 +684,13 @@ public GlideRequest listener(@Nullable RequestListener) super.listener(listener); } + @Override + @NonNull + @CheckResult + public GlideRequest addListener(@Nullable RequestListener listener) { + return (GlideRequest) super.addListener(listener); + } + @Override @NonNull public GlideRequest error(@Nullable RequestBuilder builder) { diff --git a/annotation/compiler/test/src/test/resources/LegacyGlideExtensionOptionsTest/OverrideExtend/GlideRequest.java b/annotation/compiler/test/src/test/resources/LegacyGlideExtensionOptionsTest/OverrideExtend/GlideRequest.java index d47ee27402..ee391f551e 100644 --- a/annotation/compiler/test/src/test/resources/LegacyGlideExtensionOptionsTest/OverrideExtend/GlideRequest.java +++ b/annotation/compiler/test/src/test/resources/LegacyGlideExtensionOptionsTest/OverrideExtend/GlideRequest.java @@ -670,6 +670,13 @@ public GlideRequest listener(@Nullable RequestListener) super.listener(listener); } + @Override + @NonNull + @CheckResult + public GlideRequest addListener(@Nullable RequestListener listener) { + return (GlideRequest) super.addListener(listener); + } + @Override @NonNull public GlideRequest error(@Nullable RequestBuilder builder) { diff --git a/annotation/compiler/test/src/test/resources/LegacyGlideExtensionOptionsTest/OverrideReplace/GlideRequest.java b/annotation/compiler/test/src/test/resources/LegacyGlideExtensionOptionsTest/OverrideReplace/GlideRequest.java index d47ee27402..ee391f551e 100644 --- a/annotation/compiler/test/src/test/resources/LegacyGlideExtensionOptionsTest/OverrideReplace/GlideRequest.java +++ b/annotation/compiler/test/src/test/resources/LegacyGlideExtensionOptionsTest/OverrideReplace/GlideRequest.java @@ -670,6 +670,13 @@ public GlideRequest listener(@Nullable RequestListener) super.listener(listener); } + @Override + @NonNull + @CheckResult + public GlideRequest addListener(@Nullable RequestListener listener) { + return (GlideRequest) super.addListener(listener); + } + @Override @NonNull public GlideRequest error(@Nullable RequestBuilder builder) { diff --git a/annotation/compiler/test/src/test/resources/LegacyGlideExtensionOptionsTest/SkipStaticMethod/GlideRequest.java b/annotation/compiler/test/src/test/resources/LegacyGlideExtensionOptionsTest/SkipStaticMethod/GlideRequest.java index c9124e93b6..f0377a0a7c 100644 --- a/annotation/compiler/test/src/test/resources/LegacyGlideExtensionOptionsTest/SkipStaticMethod/GlideRequest.java +++ b/annotation/compiler/test/src/test/resources/LegacyGlideExtensionOptionsTest/SkipStaticMethod/GlideRequest.java @@ -684,6 +684,13 @@ public GlideRequest listener(@Nullable RequestListener) super.listener(listener); } + @Override + @NonNull + @CheckResult + public GlideRequest addListener(@Nullable RequestListener listener) { + return (GlideRequest) super.addListener(listener); + } + @Override @NonNull public GlideRequest error(@Nullable RequestBuilder builder) { diff --git a/annotation/compiler/test/src/test/resources/LegacyGlideExtensionOptionsTest/StaticMethodName/GlideRequest.java b/annotation/compiler/test/src/test/resources/LegacyGlideExtensionOptionsTest/StaticMethodName/GlideRequest.java index c9124e93b6..f0377a0a7c 100644 --- a/annotation/compiler/test/src/test/resources/LegacyGlideExtensionOptionsTest/StaticMethodName/GlideRequest.java +++ b/annotation/compiler/test/src/test/resources/LegacyGlideExtensionOptionsTest/StaticMethodName/GlideRequest.java @@ -684,6 +684,13 @@ public GlideRequest listener(@Nullable RequestListener) super.listener(listener); } + @Override + @NonNull + @CheckResult + public GlideRequest addListener(@Nullable RequestListener listener) { + return (GlideRequest) super.addListener(listener); + } + @Override @NonNull public GlideRequest error(@Nullable RequestBuilder builder) { diff --git a/annotation/compiler/test/src/test/resources/LegacyGlideExtensionWithOptionTest/GlideRequest.java b/annotation/compiler/test/src/test/resources/LegacyGlideExtensionWithOptionTest/GlideRequest.java index b453136b6e..05b6b7d5c0 100644 --- a/annotation/compiler/test/src/test/resources/LegacyGlideExtensionWithOptionTest/GlideRequest.java +++ b/annotation/compiler/test/src/test/resources/LegacyGlideExtensionWithOptionTest/GlideRequest.java @@ -684,6 +684,13 @@ public GlideRequest listener(@Nullable RequestListener) super.listener(listener); } + @Override + @NonNull + @CheckResult + public GlideRequest addListener(@Nullable RequestListener listener) { + return (GlideRequest) super.addListener(listener); + } + @Override @NonNull public GlideRequest error(@Nullable RequestBuilder builder) {