Skip to content

[codex] cover dynamic import glob candidates#4283

Draft
andrewtdiz wants to merge 1 commit into
PerryTS:mainfrom
andrewtdiz:codex/node-compat-dynamic-import-glob-candidates
Draft

[codex] cover dynamic import glob candidates#4283
andrewtdiz wants to merge 1 commit into
PerryTS:mainfrom
andrewtdiz:codex/node-compat-dynamic-import-glob-candidates

Conversation

@andrewtdiz
Copy link
Copy Markdown
Contributor

Part of #1674.

Scope

  • Adds a Node parity fixture for directory-scoped dynamic import template literals.
  • Covers finite candidate expansion through import(./fixtures/dynamic-glob/${name}.ts).
  • Includes two local fixture modules so the test verifies both discovered candidates compile and run.

Non-goals

  • No compiler/runtime changes.
  • No package or bare-specifier wildcard support.
  • No unbounded recursive glob behavior.
  • No additional parameter type narrowing beyond the existing directory-scoped glob handling.

Validation

  • npm exec --yes --package=node@26 -- node --experimental-strip-types test-parity/node-suite/module/loader/dynamic-import-glob-candidates.ts
  • CARGO_BUILD_JOBS=1 CARGO_TARGET_DIR=/root/perry-worktrees/.build-targets/perry-dynamic-import-glob-build cargo build --release -p perry -p perry-runtime -p perry-stdlib
  • PERRY_NO_AUTO_OPTIMIZE=1 /root/perry-worktrees/.build-targets/perry-dynamic-import-glob-build/release/perry test-parity/node-suite/module/loader/dynamic-import-glob-candidates.ts -o /tmp/perry_dynamic_import_glob && /tmp/perry_dynamic_import_glob
  • PERRY_NO_AUTO_OPTIMIZE=1 CARGO_TARGET_DIR=/root/perry-worktrees/.build-targets/perry-dynamic-import-glob-build npm exec --yes --package=node@26 -- bash -lc './run_parity_tests.sh --suite node-suite --module module --filter dynamic-import-glob-candidates'
  • PERRY_NO_AUTO_OPTIMIZE=1 CARGO_TARGET_DIR=/root/perry-worktrees/.build-targets/perry-dynamic-import-glob-build npm exec --yes --package=node@26 -- bash -lc './run_parity_tests.sh --suite node-suite --module module --filter dynamic-import'
  • cargo fmt --all -- --check
  • git diff --check
  • ./scripts/check_file_size.sh

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.

1 participant