Commit d7051433 authored by Mark Tyneway's avatar Mark Tyneway

contracts-bedrock: simplify merkle trie setup

The `MerkleTrie` tests were using `CommonTest` but do not
require anything besides `FFIInterface` so instead of pulling
in all of the overhead of `CommonTest`, just deploy `FFIInterface`
on its on in the `setUp` function. This should be a slight
optimization as it reduces the amount of execution required for
setup.

Reducing diff from https://github.com/ethereum-optimism/optimism/pull/7928
parent 9575b73f
// SPDX-License-Identifier: MIT
pragma solidity 0.8.15;
import { CommonTest } from "test/CommonTest.t.sol";
import { Test } from "forge-std/Test.sol";
import { MerkleTrie } from "src/libraries/trie/MerkleTrie.sol";
import { FFIInterface } from "test/setup/FFIInterface.sol";
contract MerkleTrie_get_Test is Test {
FFIInterface ffi;
function setUp() public {
ffi = new FFIInterface();
}
contract MerkleTrie_get_Test is CommonTest {
function test_get_validProof1_succeeds() external {
bytes32 root = 0xd582f99275e227a1cf4284899e5ff06ee56da8859be71b553397c69151bc942f;
bytes memory key = hex"6b6579326262";
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment