Fix compile warning in spring-security-test#18593
Open
kmw10693 wants to merge 3 commits intospring-projects:mainfrom
Open
Fix compile warning in spring-security-test#18593kmw10693 wants to merge 3 commits intospring-projects:mainfrom
kmw10693 wants to merge 3 commits intospring-projects:mainfrom
Conversation
8dc0386 to
15a34fa
Compare
Member
|
Thanks for the Pull Request! This is will be merged into main when the build passes 😄 |
Author
Thanks! I fixed the code format style |
auto-merge was automatically disabled
February 2, 2026 18:00
Rebase failed
b8324e6 to
f77ab7a
Compare
f77ab7a to
d839cd6
Compare
Signed-off-by: Minu Kim <kmw106933@naver.com>
Signed-off-by: Minu Kim <kmw106933@naver.com>
Signed-off-by: Minu Kim <kmw106933@naver.com>
d839cd6 to
8b10fe0
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
#18440
Here's an explanation of the compiler warnings fixed in this PR:
Fixed Warnings

1. WebSecurityConfigurationTests.java
Issue: Raw type warning due to missing generic type specification in ClassUtils.getMethod() call
Fix: Added (Class<?>[]) cast to ensure generic type safety
2. OneTimeTokenAuthenticationTokenTests.java

Issue: Warning from using deprecated functionality
Fix: Added @SuppressWarnings("removal") annotation to suppress the deprecation warning
3. OneTimeTokenReactiveAuthenticationManagerTests.java

Issue: Deprecation warnings from using deprecated OneTimeTokenAuthenticationToken or related deprecated APIs throughout the test methods
Fix: Added @SuppressWarnings("removal") annotation to each test method that uses the deprecated functionality
4. AuthorityAuthorizationManagerTests.java

Issue: Ambiguous method call warnings. Passing null directly to varargs methods like hasAnyRole(String...) and hasAnyAuthority(String...) creates ambiguity - the compiler can't determine if null represents a null array or an array containing a single null element
Fix: Added explicit (String[]) cast to clarify that null represents a null array, not a single null element
5. DefaultMethodSecurityExpressionHandlerKotlinTests.kt

Issue: Kotlin's "unchecked cast" warnings when casting generic types. The compiler cannot verify at runtime that the cast to parameterized types like Map<String, String>, Collection, Array, or Stream is type-safe, since generic type information is erased at runtime
Fix: Added @Suppress("UNCHECKED_CAST") annotation to explicitly acknowledge and suppress these unavoidable warnings
6/ DelegatingAuthenticationEntryPointTests.java

Issue: Deprecation warnings from using the deprecated DelegatingAuthenticationEntryPoint class or its constructors/methods
Fix: Added @SuppressWarnings("removal") annotation to each test method that uses the deprecated functionality
7. OneTimeTokenAuthenticationFilterTests.java

Issue: Deprecation warnings from using deprecated OneTimeTokenAuthenticationFilter or related one-time token authentication APIs
Fix: Added @SuppressWarnings("removal") annotation to each test method that uses the deprecated functionality