Skip to content

Commit fe841c0

Browse files
morningmanclaude
andcommitted
[test](fe) Use mixed-case caller keys in the partition path parse test
### What problem does this PR solve? Issue Number: None Related PR: #69001 Problem Summary: parseColumnsFromPathPreservesNullMetadataAndInputKeys checks that a case-insensitive parse lowercases its own copy of the partition keys and leaves the caller's list alone. The caller's keys were already lowercase, so a parse that lowercased the caller's list in place would still have passed. The caller now passes Region and Dt, the path spells them REGION and dt, and the test asserts the list still reads Region, Dt after the parse. ### Release note None ### Check List (For Author) - Test: Unit Test - BrokerUtilTest passes. With FilePartitionUtils changed to lowercase the caller's list in place, the new assertion fails; the old fixture passed under the same change. - Behavior changed: No - Does this need documentation: No Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
1 parent ed4c79c commit fe841c0

1 file changed

Lines changed: 3 additions & 3 deletions

File tree

‎fe/fe-core/src/test/java/org/apache/doris/common/util/BrokerUtilTest.java‎

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -130,13 +130,13 @@ public void parseColumnsFromPath() {
130130
public void parseColumnsFromPathPreservesNullMetadataAndInputKeys() throws Exception {
131131
// A case-insensitive parse lowercases its own copy of the keys, not the caller's list, and turns the Hive
132132
// default partition into SQL NULL.
133-
List<String> partitionKeys = Lists.newArrayList("region", "dt");
133+
List<String> partitionKeys = Lists.newArrayList("Region", "Dt");
134134
FilePartitionUtils.ParsedColumnsFromPath parsed = FilePartitionUtils.parseColumnsFromPathWithNullInfo(
135-
"hdfs://host/table/Region=cn/Dt=" + ConnectorPartitionValues.NULL_PARTITION_NAME + "/data.parquet",
135+
"hdfs://host/table/REGION=cn/dt=" + ConnectorPartitionValues.NULL_PARTITION_NAME + "/data.parquet",
136136
partitionKeys, false, false);
137137
Assertions.assertEquals(Lists.newArrayList("cn", ""), parsed.getValues());
138138
Assertions.assertEquals(Lists.newArrayList(false, true), parsed.getIsNull());
139-
Assertions.assertEquals(Lists.newArrayList("region", "dt"), partitionKeys);
139+
Assertions.assertEquals(Lists.newArrayList("Region", "Dt"), partitionKeys);
140140

141141
// A literal \N is data on the query path.
142142
parsed = FilePartitionUtils.parseColumnsFromPathWithNullInfo(

0 commit comments

Comments
 (0)