Support EIP-712 cheatcodes in Solidity Test#260
Merged
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
Contributor
There was a problem hiding this comment.
Pull request overview
Adds documentation for newly supported EIP-712 hashing cheatcodes in Hardhat Solidity tests, including the required test.solidity.eip712Types configuration and a dedicated guide for collecting/using EIP-712 struct types.
Changes:
- Document new
test.solidity.eip712Typesconfiguration and link it to the relevant cheatcodes and guide. - Add new cheatcode reference pages for
eip712HashType,eip712HashStruct, andeip712HashTypedData, plus a new “EIP-712 type hashing” testing guide. - Remove EIP-712 items from the “unsupported cheatcodes” list and bump
@nomicfoundation/hardhat-errors(and lockfile updates).
Reviewed changes
Copilot reviewed 7 out of 8 changed files in this pull request and generated 3 comments.
Show a summary per file
| File | Description |
|---|---|
| src/content/docs/docs/reference/configuration.mdx | Documents the new test.solidity.eip712Types config block and links to cheatcodes/guide. |
| src/content/docs/docs/reference/cheatcodes/Utilities/eip712-hash-typed-data.mdx | Adds reference docs for hashing full EIP-712 typed-data JSON payloads. |
| src/content/docs/docs/reference/cheatcodes/Utilities/eip712-hash-type.mdx | Adds reference docs for hashing canonical EIP-712 type strings (by name or definition). |
| src/content/docs/docs/reference/cheatcodes/Utilities/eip712-hash-struct.mdx | Adds reference docs for hashing EIP-712 structs by registered type name + ABI-encoded value. |
| src/content/docs/docs/reference/cheatcodes/unsupported-cheatcodes.mdx | Removes EIP-712 cheatcodes from the “unsupported” list. |
| src/content/docs/docs/guides/testing/eip712-types.mdx | Adds a new guide explaining configuration and usage patterns for EIP-712 hashing in Solidity tests. |
| package.json | Bumps @nomicfoundation/hardhat-errors dependency. |
| pnpm-lock.yaml | Updates lockfile for the dependency bump (including transitive updates). |
Files not reviewed (1)
- pnpm-lock.yaml: Language not supported
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
| '"Mail":[{"name":"from","type":"Person"},{"name":"to","type":"Person"},{"name":"contents","type":"string"}],' | ||
| '"Person":[{"name":"wallet","type":"address"},{"name":"name","type":"string"}]' | ||
| '},' | ||
| '"primaryType":"Mail",' |
Contributor
Author
There was a problem hiding this comment.
True, they are not valid, but the idea was to simplify the reading by using shorter fake addresses
5c94925 to
9816c19
Compare
…site into EIP-712-cheatcodes-hh
kanej
approved these changes
May 20, 2026
Member
kanej
left a comment
There was a problem hiding this comment.
I did a run through manually of the guide. LGTM!
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Docs for Hardhat PR: NomicFoundation/hardhat#8243
Links to modified pages in the preview webiste: