Skip to content

Conversation

@Kota-Jagadeesh
Copy link
Collaborator

Description (required)

Fixes #5923

What changes did you make and why?

  • the logic update: Modified the findUniqueFileName in UploadWorker.kt to replace the old 5-digit random hash format (12345) with the requested 3-digit hash format #XXX.
  • test implementation: Created UploadWorkerTest.kt to ensure the filename generation logic is robust.
  • visibility vhange: updated findUniqueFileName visibility to internal to allow unit test access while maintaining module-level encapsulation.

Why?
The previous 5-digit format did not meeet the updated project requirements. these changes align the naming convention with the #XXX standard and provide automated testing to ensure filenames are generated correctly and remain unique.


Tests performed (required)

Tested ProdDebug build variant on Local Unit Tests (JUnit 4).

@Kota-Jagadeesh Kota-Jagadeesh self-assigned this Jan 22, 2026
@Kota-Jagadeesh Kota-Jagadeesh changed the title Fix 5923 tests Add unit tests for findUniqueFileName Jan 22, 2026
@github-actions
Copy link

✅ Generated APK variants!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Write tests for findUniqueFilename() in UploadWorker.kt

1 participant