Apply governor mutation based on existing datum

This commit is contained in:
Daniel Farrelly 2023-03-29 21:33:09 +01:00 committed by Emily Martins
parent 9e18c294f8
commit ad80e9f685
3 changed files with 71 additions and 21 deletions

View file

@ -47,7 +47,16 @@ specs =
, effectSucceedsWith
"effect validator should pass"
effectValidator
(mkEffectDatum validNewGovernorDatum)
( mkEffectDatum
( GovernorDatum
def
(ProposalId 0)
def
def
3
)
validNewGovernorDatum
)
(ScriptContext (mkEffectTxInfo validNewGovernorDatum) (Spending effectRef))
]
, group
@ -70,7 +79,16 @@ specs =
, effectFailsWith
"effect validator should fail"
effectValidator
(mkEffectDatum validNewGovernorDatum)
( mkEffectDatum
( GovernorDatum
def
(ProposalId 0)
def
def
3
)
validNewGovernorDatum
)
(ScriptContext (mkEffectTxInfo invalidNewGovernorDatum) (Spending effectRef))
]
]