Repository navigation
test: cover malformed percent-encoded sequences - #459
Palendromas1 wants to merge 3 commits into
Conversation
|
The coverage is useful, but this PR needs a few improvements before merging. See commit afaeeac. In this PR:
My commit afaeeac replaces the existing truncation test with parameterized cases, preserving its valid-prefix scenario and exception-cause assertion. A separate parameterized test uses It also retains the Javadoc clarification and the distinct RFC1522 empty-content test, with a comment explaining that accepting empty content preserves existing permissive behavior. This provides stronger regression protection without accumulating overlapping test methods. Temporary mutation checks confirmed that the revised tests detect broken validation of either digit, swallowed truncation errors, and lost exception causes. Closing; you are credited in |
Summary
Adds test coverage for malformed percent-encoded sequences in
PercentCodec.Changes
%and%2).%GGand%2G).DecoderException.Validation
mvn -Dtest=PercentCodecTest test