OpenZeppelin / OpenZeppelin/Event-Scanner
Update Tests So That The Node They're Running Against is Configurable
Nobody has claimed this yet.
- Dominant language
- Rust
- Stars
- 19
- Forks
- 7
- Avg merge
- 2h 15m
- Merged PRs (30d)
- 4
Description
- node used in tests should be abstracted away (e.g. a wrapper that wraps the actual underlying node and exposes or implements all of the necessary functionality to set up the node)
- support Anvil, Geth, Reth and Nethermind nodes
- each node support can be added as part of separate PRs for easier review
- add CI job that runs all tests against each supported node
Tests are currently hardcoded to run against Anvil in-memory node. This is fine in general, but given the slight differences in behavior between different nodes e.g. when fetching the finalized block on a zero-height chain (i.e. newly created chain with no blocks mined), it is safe to assume there might be other differences.
Since event-scanner implies support for all nodes, it makes sense to run the whole event scanner test suite against other nodes as well.
For context, when fetching the finalized block on a zero-block-height chain:
- Anvil: returns the genesis block
- Reth: returns
None - Geth: returns an error
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by locating the test setup that is hardcoded to use Anvil and identify the node functionality the suite requires. Review how the test environment can abstract node setup, then verify support for each requested node and add CI coverage that runs the full event-scanner test suite against them.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- rust
- Domain
- ci-cd, testing
- Issue type
- Feature
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100