File tree Expand file tree Collapse file tree 7 files changed +370
-347
lines changed
templates/blockchain_test Expand file tree Collapse file tree 7 files changed +370
-347
lines changed Original file line number Diff line number Diff line change @@ -89,7 +89,7 @@ tf = "cli.pytest_commands.fill:tf"
89
89
checkfixtures = " cli.check_fixtures:check_fixtures"
90
90
consume = " cli.pytest_commands.consume:consume"
91
91
genindex = " cli.gen_index:generate_fixtures_index_cli"
92
- gentest = " cli.gentest:make_test "
92
+ gentest = " cli.gentest:generate "
93
93
pyspelling_soft_fail = " cli.tox_helpers:pyspelling"
94
94
markdownlintcli2_soft_fail = " cli.tox_helpers:markdownlint"
95
95
order_fixtures = " cli.order_fixtures:order_fixtures"
Load Diff This file was deleted.
Original file line number Diff line number Diff line change
1
+ """
2
+ Generate a Python blockchain test from a transaction hash.
3
+
4
+ This script can be used to generate Python source for a blockchain test case
5
+ that replays a mainnet or testnet transaction from its transaction hash.
6
+
7
+ Requirements:
8
+
9
+ 1. Access to an archive node for the network where the transaction
10
+ originates. A provider may be used.
11
+ 2. The transaction hash of a type 0 transaction (currently only legacy
12
+ transactions are supported).
13
+
14
+ Example Usage:
15
+
16
+ 1. Generate a test for a transaction with hash
17
+
18
+ ```console
19
+ uv run gentest \
20
+ 0xa41f343be7a150b740e5c939fa4d89f3a2850dbe21715df96b612fc20d1906be \
21
+ tests/paris/test_0xa41f.py
22
+ ```
23
+
24
+ 2. Fill the test:
25
+
26
+ ```console
27
+ fill --fork=Paris tests/paris/test_0xa41f.py
28
+ ```
29
+
30
+ Limitations:
31
+
32
+ 1. Only legacy transaction types (type 0) are currently supported.
33
+ """
34
+
35
+ from .cli import generate # noqa: 401
You can’t perform that action at this time.
0 commit comments