Skip to content

Conversation

Shadow2121
Copy link

@Shadow2121 Shadow2121 commented Mar 20, 2025

Modified validation conditions for more meaningful logs and error handling.

Type of change

  • code smell

How Has This Been Tested?

I ran existing test cases from PlaylistApiRetrofitTest

  • createPlaylistUsesCorrectValuesToCreateHttpCall
  • createPlaylistExecutesHttpCall
  • createPlaylistThrowsSpotifyActionFailedExceptionWhenError
  • createPlaylistThrowsHttpRequestFailedWhenHttpFails
  • createPlaylistThrowsIllegalArgumentExceptionWhenUserIdIsNull
  • createPlaylistThrowsIllegalArgumentExceptionWhenUserIdIsEmptry
  • createPlaylistThrowsIllegalArgumentExceptionWhenNameIsNullInsideRequestBody
  • createPlaylistThrowsIllegalArgumentExceptionWhenNameIsEmptyInsideRequestBody
  • uploadCoverImageToPlaylistUsesCorrectValuesToCreateHttpCall
  • uploadCoverImageToPlaylistExecutesHttpCall
  • uploadCoverImageToPlaylistThrowsSpotifyActionFailedExceptionWhenError
  • uploadCoverImageToPlaylistThrowsHttpRequestFailedWhenHttpFails
  • uploadCoverImageToPlaylistThrowsIllegalArgumentExceptionWhenPlaylistIdIsNull
  • uploadCoverImageToPlaylistThrowsIllegalArgumentExceptionWhenPlaylistIdEmpty
  • uploadCoverImageToPlaylistThrowsIllegalArgumentExceptionWhenBase64EncodedJpegImageIsNull
  • uploadCoverImageToPlaylistThrowsIllegalArgumentExceptionWhenBase64EncodedJpegImageIsEmpty

Checklist

  • My code follows the (style) guidelines of this project
  • I have performed a self-review of my own code
  • My changes generate no new warnings
  • New and existing unit tests pass locally with my changes

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