FFFF
Skip to content

Add @Multipart/@Part Retrofit lint updates#320

Merged
ryan-moore-slack merged 3 commits intomainfrom
ryanmoore/retrofit-multipart-updates
Oct 14, 2024
Merged

Add @Multipart/@Part Retrofit lint updates#320
ryan-moore-slack merged 3 commits intomainfrom
ryanmoore/retrofit-multipart-updates

Conversation

@ryan-moore-slack
Copy link
Copy Markdown
Contributor
@ryan-moore-slack ryan-moore-slack commented Oct 9, 2024

Summary

This PR updates the RetrofitUsageDetector to include support for @Multipart annotated methods and @Part annotated parameters per Retrofit doc. Added test cases for new lints and success path.

Requirements (place an x in each [ ])

The following point can be removed after setting up CI (such as Travis) with coverage reports (such as Codecov)

  • [x ] I've written tests to cover the new code and functionality included in this PR.

The following point can be removed after setting up a CLA reporting tool such as cla-assistant.io

val annotationsByFqcn = node.uAnnotations.associateBy { it.qualifiedName }

val isFormUrlEncoded = FQCN_FORM_ENCODED in annotationsByFqcn
val isMultipart = FQCN_MULTIPART in annotationsByFqcn
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nit before you merge: move this down to the line before the if statement that uses it

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

resolved in 6161a32

@ryan-moore-slack ryan-moore-slack added this pull request to the merge queue Oct 14, 2024
Merged via the queue into main with commit 3344c3a Oct 14, 2024
@ryan-moore-slack ryan-moore-slack deleted the ryanmoore/retrofit-multipart-updates branch October 14, 2024 15:59
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants

0