Skip to content

Commit b57ce5f

Browse files
committed
feat(tests): add db-sync check for transaction spending
- Add optional db-sync transaction check in `TestLockingV2.test_spend_locked_utxo`
1 parent 5046f73 commit b57ce5f

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

cardano_node_tests/tests/tests_plutus_v2/test_spend_raw.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,7 @@
1313
from cardano_node_tests.tests import plutus_common
1414
from cardano_node_tests.tests.tests_plutus_v2 import spend_raw
1515
from cardano_node_tests.utils import dbsync_queries
16+
from cardano_node_tests.utils import dbsync_utils
1617
from cardano_node_tests.utils import helpers
1718

1819
LOGGER = logging.getLogger(__name__)
@@ -64,6 +65,7 @@ def test_txout_locking(
6465
* check that the expected amount was locked at the script address
6566
* spend the locked UTxO
6667
* check that the expected UTxOs were correctly spent
68+
* (optional) check transactions in db-sync
6769
"""
6870
temp_template = common.get_test_id(cluster)
6971
amount = 2_000_000
@@ -172,6 +174,8 @@ def test_txout_locking(
172174

173175
assert helpers.is_in_interval(fee, expected_fee_redeem, frac=0.15)
174176

177+
dbsync_utils.check_tx(cluster_obj=cluster, tx_raw_output=tx_output_redeem)
178+
175179
@allure.link(helpers.get_vcs_link())
176180
@pytest.mark.smoke
177181
@pytest.mark.testnets

0 commit comments

Comments
 (0)