Skip to content

test: cover case-insensitive resource path collisions - #110

Open
black1771 wants to merge 1 commit into
REAndroid:mainfrom
black1771:test/apkeditor-243-case-collision
Open

black1771 wants to merge 1 commit into
REAndroid:mainfrom
black1771:test/apkeditor-243-case-collision

Conversation

@black1771

Copy link
Copy Markdown

Summary

Adds a self-contained JUnit regression test for case-insensitive resource path collisions, related to REAndroid/APKEditor#243.

Test coverage

  • Reproduces collisions such as "res/Zy.xml" and "res/zy.xml".
  • Enables case-insensitive path sanitization.
  • Verifies that all resulting aliases are unique.
  • Checks that the number of input sources remains unchanged.
  • Verifies that the original source content is preserved.

Verification

  • Gradle test passed on Android Termux.
  • 1 test passed, 0 failures, 0 errors.
  • No external APK fixture or network access required.

This PR adds regression test coverage for the existing fix in commit "089ec68".

@REAndroid

Copy link
Copy Markdown
Owner

Thank you !

Do you have an idea to test with file system/os instead of setCaseInsensitive ? I know its complicated, your test is enough for now, please confirm or I am going to merge it

@black1771

Copy link
Copy Markdown
Author

Thank you!

I confirm that the current test is sufficient for now.

Testing directly against different file systems or operating systems would be more realistic, but it would also require a more complex test environment.

The current test covers the case-insensitive resource path collision scenario.

You can go ahead and merge PR #110.

Thanks for reviewing!

@REAndroid

Copy link
Copy Markdown
Owner

test failed, check the actions

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