Skip to content

fix(bindings/nodejs): Align versioned list startAfter test#7579

Merged
Xuanwo merged 1 commit into
apache:mainfrom
ddupg:codex/ddu-32-fix-nodejs-versioned-list-startafter-test
May 21, 2026
Merged

fix(bindings/nodejs): Align versioned list startAfter test#7579
Xuanwo merged 1 commit into
apache:mainfrom
ddupg:codex/ddu-32-fix-nodejs-versioned-list-startafter-test

Conversation

@ddupg
Copy link
Copy Markdown
Member

@ddupg ddupg commented May 21, 2026

Which issue does this PR close?

N/A. This fixes a CI-only behavior test regression after TOS versioning support was enabled.

https://github.com/apache/opendal/actions/runs/26219601739/job/77150890707

Rationale for this change

The Node.js binding list with versions and start after test was comparing Entry[] directly with path strings. It also expected one result per object, but versions: true returns one entry per object version.

This was exposed by the TOS behavior job because TOS now enables both list_with_versions and list_with_start_after without overriding versioning in CI.

What changes are included in this PR?

  • Map listed entries to entry.path() before comparing.
  • Expect two entries for each object written twice.
  • Apply the same assertion fix to async and sync Node.js list option tests.

Are there any user-facing changes?

No. This only fixes Node.js binding behavior test expectations.

AI Usage Statement

Used OpenAI Codex to investigate the CI failure and prepare this patch.

Validation:

  • OPENDAL_TEST=tos cargo test --test behavior --features services-tos,tests behavior::test_list_with_versions_and_start_after -- --test-threads=1 --show-output
  • OPENDAL_TEST=tos pnpm test -- tests/service.test.mjs -t "list with versions and start after" --testTimeout=600000 --hookTimeout=600000
  • pnpm exec prettier --check tests/suites/asyncListOptions.suite.mjs tests/suites/syncListOptions.suite.mjs

Change-Id: I4e4642441cc648e88b56bfd1b5110187fde22ad4
@ddupg ddupg marked this pull request as ready for review May 21, 2026 12:18
@ddupg ddupg requested a review from suyanhanx as a code owner May 21, 2026 12:18
@dosubot dosubot Bot added size:XS This PR changes 0-9 lines, ignoring generated files. releases-note/fix The PR fixes a bug or has a title that begins with "fix" labels May 21, 2026
@dosubot dosubot Bot added the lgtm This PR has been approved by a maintainer label May 21, 2026
@Xuanwo Xuanwo merged commit 35e7bea into apache:main May 21, 2026
65 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

lgtm This PR has been approved by a maintainer releases-note/fix The PR fixes a bug or has a title that begins with "fix" size:XS This PR changes 0-9 lines, ignoring generated files.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants