A conformance harness for MRC-13 (Validator Metadata Registry) deployments on Monad. Point it at any deployed registry and it runs the standard behavioral checks against the live contract and prints a pass/fail checklist.
This complements an implementation's own unit tests rather than repeating them. A project's tests prove that project's contract; this harness verifies that a deployed instance behaves to spec, so several independent implementations can show the same checklist. It follows the same idea as monad-rpc-conformance: falsifiable checks against a live target, with the evidence in the report.
Only the standardized MRC-13 behavior. Delegation naming and deleteMetadata are
implementation-defined extensions and are left out of the core checks.
read.getMetadata.shape- the six-field struct (name, website, description, logo, socials, additionalInfo)read.getName.consistency- getName equals getMetadata().nameread.hasMetadata.consistency- hasMetadata agrees with whether a record existsread.event.decodable- MetadataUpdated decodes to the standard shapesim.unauthorized.rejected- a non-authority setMetadata reverts (eth_call, no funds)sim.unknownValidator.rejected- setMetadata for a validator with no staking authority revertswrite.setMetadata.persistsAndEmits- a record written by the authority persists and emits MetadataUpdatedwrite.updateMetadataField.single- updateMetadataField changes one field and leaves the rest
Read-only and simulation checks need only an RPC and the registry address. The two write checks need a signer that is a validator's staking authority; they mutate that validator's record and restore it afterwards. Without a key the harness runs read-only plus simulation and marks the write checks inconclusive.
npm install
# read-only + simulation
npm run check -- --rpc <url> --registry <addr> --network monad-testnet --validator <id>
# full run (write checks): signer must be the validator's authority
MRC13_PRIVATE_KEY=0x... npm run check -- \
--rpc <url> --registry <addr> --network monad-testnet --validator <id> --out reports/runFlags: --rpc, --registry, --network, --validator <id>,
--key-env <VAR> (default MRC13_PRIVATE_KEY), --key <hex> (discouraged),
--out <dir>, --fail-on-violation.
The private key is read from an environment variable by default so it stays out of shell history.
Against the reference deployment on Monad testnet
(0x3f084CAF88F8894f6c83cf40b9cA7e792D9F221B, validator 267 as the test record):
all eight checks conform, and the validator's record is restored afterwards. The
generated report is in reports/.
- Local anvil mode with a mock staking precompile, so the checks run in CI with no funds and no live deployment
- More cases as the MRC-13 Test Cases section of the spec firms up (delegation scoping, rotation retirement, deleteMetadata for implementations that include it)
MIT