Skip to content

test: remove --proxyquire-shim from common, bigquery, datastore, and dns - #9643

Draft
danieljbruce wants to merge 4 commits into
fix/remove-proxyquire-shim-sinonfrom
fix/remove-proxyquire-shim-core-dns-ds-bq
Draft

danieljbruce wants to merge 4 commits into
fix/remove-proxyquire-shim-sinonfrom
fix/remove-proxyquire-shim-core-dns-ds-bq

Conversation

@danieljbruce

@danieljbruce danieljbruce commented Oct 15, 2026 •

Copy link
Copy Markdown
Contributor

Description

Replaces global proxyquire shim with local test helper in four packages.

Impact

Removes --proxyquire-shim from common, bigquery, datastore, and google-cloud-dns test scripts.

Changes

Testing

  • Executed pnpm test under both Node.js and Bun (JS_RUNTIME=bun) in core/common, handwritten/bigquery, handwritten/datastore, and handwritten/google-cloud-dns.
  • Verified strict lint and type checks pass via bin/linter.mjs --strict.

Alternatives

  • Not merging this pull request was considered, which would keep these four packages coupled to the global bin/proxyquire-bun-shim.cjs preload shim.

@gemini-code-assist gemini-code-assist Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request replaces the external proxyquire dependency with a custom local implementation across multiple packages and updates the test scripts to remove the --proxyquire-shim flag. Feedback on the new proxyquire.ts files highlights a bug in the hasOwn helper, which currently only checks for 'object' types and fails to recognize function-based stubs, thereby ignoring @noCallThru and @global behaviors. It is recommended to update hasOwn to support both 'object' and 'function' types.

Comment thread core/common/test/proxyquire.ts Outdated
Comment thread handwritten/bigquery/test/proxyquire.ts Outdated
Comment thread handwritten/datastore/test/proxyquire.ts Outdated
Comment thread handwritten/google-cloud-dns/test/proxyquire.ts Outdated
@danieljbruce
danieljbruce added this pull request to stack #9647 October 15, 2026 21:18

This branch has not been deployed

No deployments
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