Skip to content

Fix SingleDeviceViewOperatorTest row assertion - #17995

Merged
jt2594838 merged 1 commit into
apache:masterfrom
Caideyipi:fix/single-device-view-operator-test
Jun 22, 2026
Merged

jt2594838 merged 1 commit into
apache:masterfrom
Caideyipi:fix/single-device-view-operator-test

Conversation

@Caideyipi

Copy link
Copy Markdown
Collaborator

Description

This PR fixes a fragile assertion in SingleDeviceViewOperatorTest. The test used to derive the expected timestamp from the TsBlock index and assumed each returned block contains 20 rows. The operator contract does not guarantee that block size, so when the child operator returns a larger block, the expected timestamp resets incorrectly and the test can fail with expected 20 but was 320.

The test now validates timestamps by a global row counter across all returned TsBlocks, while preserving the existing value and null-column checks.

This is unrelated to the show receivers changes: the current show-receivers branch does not modify SingleDeviceViewOperatorTest, SingleDeviceViewOperator, FullOuterTimeJoinOperator, or SeriesReaderTestUtil.

Tests

  • mvn -pl iotdb-core/datanode spotless:apply
  • mvn -pl iotdb-core/datanode -Dtest=SingleDeviceViewOperatorTest#singleDeviceViewOperatorTest test (not completed locally: dependency resolution fails before tests run because snapshot artifacts such as org.apache.iotdb:node-commons:2.0.7-SNAPSHOT are unavailable from the configured Maven repositories)

@jt2594838
jt2594838 merged commit 5f96833 into apache:master Jun 22, 2026
40 checks passed
@jt2594838
jt2594838 deleted the fix/single-device-view-operator-test branch June 22, 2026 09:32
MileaRobertStefan pushed a commit to MileaRobertStefan/iotdb that referenced this pull request Jun 26, 2026
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