Skip to content

Commit 3630d4b

Browse files
authored
chore(fill,spec): write fixture-format not fixture_format to fixtures (#1295)
1 parent d41ca05 commit 3630d4b

File tree

3 files changed

+6
-3
lines changed

3 files changed

+6
-3
lines changed

docs/CHANGELOG.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@ Test fixtures for use by clients are available for each release on the [Github r
1111
The following changes may be potentially breaking (all clients were tested with these changes with the state test format, but not the blockchain test format):
1212

1313
- 💥 Add a `yParity` field (that duplicates `v`) to transaction authorization tuples in fixture formats to have fields that conform to EIP-7702 spec, resolves [erigontech/erigon#14073](https://github.com/erigontech/erigon/issues/14073) ([#1286](https://github.com/ethereum/execution-spec-tests/pull/1286)).
14+
- 💥 Rename the recently introduced `_info` field `fixture_format` to `fixture-format` for consistency [#1295](https://github.com/ethereum/execution-spec-tests/pull/1295).
1415

1516
### 🛠️ Framework
1617

src/cli/eofwrap.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -313,7 +313,7 @@ def _wrap_fixture(self, fixture: BlockchainFixture, traces: bool):
313313
fork=Osaka,
314314
fixture_format=BlockchainFixture,
315315
)
316-
result.info["fixture_format"] = "blockchain_test"
316+
result.info["fixture-format"] = "blockchain_test"
317317
if traces:
318318
print_traces(t8n.get_traces())
319319
return result

src/ethereum_test_fixtures/base.py

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,9 @@ def fixture_format_discriminator(v: Any) -> str | None:
3131
assert info_dict is not None, (
3232
f"Fixture does not have an info field, cannot determine fixture format: {v}"
3333
)
34-
fixture_format = info_dict.get("fixture_format")
34+
fixture_format = info_dict.get("fixture-format")
35+
if not fixture_format:
36+
fixture_format = info_dict.get("fixture_format")
3537
assert fixture_format is not None, f"Fixture format not found in info field: {info_dict}"
3638
return fixture_format
3739

@@ -124,7 +126,7 @@ def fill_info(
124126
self.info["filling-transition-tool"] = t8n_version
125127
self.info["description"] = test_case_description
126128
self.info["url"] = fixture_source_url
127-
self.info["fixture_format"] = self.format_name
129+
self.info["fixture-format"] = self.format_name
128130
if ref_spec is not None:
129131
ref_spec.write_info(self.info)
130132
if _info_metadata:

0 commit comments

Comments
 (0)