Skip to content

Commit 64dfb95

Browse files
committed
test: assert reference script size
Add assertion to verify that the reference script size returned by `get_ref_script_size` matches expected values.
1 parent 43d4a42 commit 64dfb95

1 file changed

Lines changed: 10 additions & 0 deletions

File tree

cardano_node_tests/tests/tests_plutus_v2/test_mint_build.py

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -244,6 +244,16 @@ def test_minting_ref_one_token(
244244
expected_costs=[script_expected_fee["cost"]],
245245
)
246246

247+
ref_size = cluster.g_query.get_ref_script_size(utxo=reference_utxo)["refInputScriptSize"]
248+
expected_sizes = {
249+
"v2": 1893,
250+
"v3": 6,
251+
}
252+
expected_size = expected_sizes[plutus_version]
253+
assert ref_size == expected_size, (
254+
f"Unexpected reference script size: expected {expected_size}, got {ref_size}"
255+
)
256+
247257
@allure.link(helpers.get_vcs_link())
248258
@common.PARAM_PLUTUS2ONWARDS_VERSION
249259
@pytest.mark.smoke

0 commit comments

Comments
 (0)