Skip to content

Commit 106d6e3

Browse files
test_mint_build.py
1 parent 12edcfe commit 106d6e3

File tree

1 file changed

+13
-3
lines changed

1 file changed

+13
-3
lines changed

cardano_node_tests/tests/tests_plutus_v2/test_mint_build.py

Lines changed: 13 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -246,9 +246,19 @@ def test_minting_ref_one_token(
246246

247247
ref_size_data = cluster.g_query.get_ref_script_size(utxo=reference_utxo)
248248

249-
ref_size = ref_size_data.get("refScriptSize") or ref_size_data.get("refInputScriptSize")
250-
assert ref_size is not None, f"Missing refScriptSize field in output: {ref_size_data}"
251-
assert ref_size >= 0, f"refScriptSize must be non-negative, got {ref_size}"
249+
ref_size = ref_size_data.get("refInputScriptSize")
250+
assert ref_size is not None, f"Missing refInputScriptSize field in output: {ref_size_data}"
251+
252+
expected_sizes = {
253+
"v2": 1893,
254+
"v3": 6,
255+
}
256+
expected_size = expected_sizes.get(plutus_version)
257+
assert expected_size is not None, f"Unexpected Plutus version: {plutus_version}"
258+
259+
assert ref_size == expected_size, (
260+
f"Unexpected reference script size: expected {expected_size}, got {ref_size}"
261+
)
252262

253263
@allure.link(helpers.get_vcs_link())
254264
@common.PARAM_PLUTUS2ONWARDS_VERSION

0 commit comments

Comments
 (0)