Description
Follow-up from PR #357 review comment by @auyidi1.
All 7 wireFormat tests added in #357 call parse_with_schema_inner directly. There is no unit test coverage for the avro_init configuration parsing logic itself.
Missing Test Coverage
The following scenarios need unit tests:
- Case-insensitive matching — e.g.,
"CONFLUENT", "Confluent", " raw " (trim + lowercase)
- Unknown value defaulting — e.g.,
"invalid" → Auto with warning
- Missing wireFormat — defaults to
Auto
OnceLock::set behavior — the let _ = WIRE_FORMAT.set(...) silently ignores errors if called twice
Location
src/500-application/512-avro-to-json/operators/avro-to-json/src/lib.rs
Context
PR #357 introduced the WireFormat enum and avro_init configuration parsing with trim().to_lowercase() transformations. While integration testing may catch some of these, dedicated unit tests for the config parsing logic would be valuable given the string transformations involved.
Related
Description
Follow-up from PR #357 review comment by @auyidi1.
All 7 wireFormat tests added in #357 call
parse_with_schema_innerdirectly. There is no unit test coverage for theavro_initconfiguration parsing logic itself.Missing Test Coverage
The following scenarios need unit tests:
"CONFLUENT","Confluent"," raw "(trim + lowercase)"invalid"→Autowith warningAutoOnceLock::setbehavior — thelet _ = WIRE_FORMAT.set(...)silently ignores errors if called twiceLocation
src/500-application/512-avro-to-json/operators/avro-to-json/src/lib.rsContext
PR #357 introduced the
WireFormatenum andavro_initconfiguration parsing withtrim().to_lowercase()transformations. While integration testing may catch some of these, dedicated unit tests for the config parsing logic would be valuable given the string transformations involved.Related