Skip to content

chore: pin OZ confidential to v0.4.0 and simplify test helpers#3

Merged
poppyseedDev merged 1 commit into
mainfrom
address-review-feedback
May 5, 2026
Merged

chore: pin OZ confidential to v0.4.0 and simplify test helpers#3
poppyseedDev merged 1 commit into
mainfrom
address-review-feedback

Conversation

@poppyseedDev

@poppyseedDev poppyseedDev commented May 5, 2026

Copy link
Copy Markdown
Contributor

Summary

Addresses review feedback on the template:

  • Pin @openzeppelin-confidential-contracts to v0.4.0 instead of commit hash 6edd293. Adds explicit @openzeppelin/contracts(-upgradeable)/ remappings since v0.4.0 ships a lib/ folder with alias stubs that otherwise hijack Forge's auto-remap fallback used inside forge-fhevm.
  • Replace hardcoded ALICE_PK constant with forge-std's makeAccount("alice") helper. Returns an Account { addr, key } and labels the address in traces.
  • New userDecryptAs(pk, handle, contract) helper that wraps signUserDecrypt + userDecrypt into a single call, removing the redundant signature step at every test site.

forge-fhevm is left on its commit pin since it has no released tag yet (also flagged in review).

Test plan

  • forge clean && forge build — succeeds
  • forge test — 3/3 passing
  • CI green

Address review feedback:

- Pin @openzeppelin-confidential-contracts to tagged release v0.4.0
  instead of commit hash 6edd293. Add explicit @openzeppelin/contracts(-upgradeable)/
  remappings, since v0.4.0 ships a lib/ folder with alias stubs that
  otherwise hijack forge's auto-remap fallback used by forge-fhevm.
- Replace hardcoded ALICE_PK constant with forge-std's makeAccount("alice")
  helper, which returns an Account { addr, key } and labels the address.
- Add a userDecryptAs(pk, handle, contract) helper that combines
  signUserDecrypt and userDecrypt into a single call site.
@poppyseedDev poppyseedDev merged commit dddecd7 into main May 5, 2026
4 checks passed
@poppyseedDev poppyseedDev deleted the address-review-feedback branch May 5, 2026 12:56
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