forked from ethereum/execution-specs
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathtest_evm_tools.py
42 lines (35 loc) · 828 Bytes
/
test_evm_tools.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
from functools import partial
from typing import Dict
import pytest
from tests.helpers import TEST_FIXTURES
from tests.helpers.load_evm_tools_tests import (
fetch_evm_tools_tests,
idfn,
load_evm_tools_test,
)
ETHEREUM_TESTS_PATH = TEST_FIXTURES["ethereum_tests"]["fixture_path"]
TEST_DIR = f"{ETHEREUM_TESTS_PATH}/GeneralStateTests/"
FORK_NAME = "Istanbul"
run_evm_tools_test = partial(
load_evm_tools_test,
fork_name=FORK_NAME,
)
SLOW_TESTS = (
"CALLBlake2f_MaxRounds",
"CALLCODEBlake2f",
"CALLBlake2f",
"loopExp",
"loopMul",
)
@pytest.mark.evm_tools
@pytest.mark.parametrize(
"test_case",
fetch_evm_tools_tests(
TEST_DIR,
FORK_NAME,
SLOW_TESTS,
),
ids=idfn,
)
def test_evm_tools(test_case: Dict) -> None:
run_evm_tools_test(test_case)