How do I test different plutus functions to see if its applicable to be used in my code. How would I create the parameters that these functions would take in.
For example below is a Vesting contract from the Plutus-Pionner-Program. How do i see what happenes when you run this function.How do I test out what each individual function return when a parameter is passed in.
give :: AsContractError e => GiveParams -> Contract w s e ()
give gp = do
let dat = VestingDatum
{ beneficiary = gpBeneficiary gp
, deadline = gpDeadline gp
}
tx = Constraints.mustPayToTheScript dat $ Ada.lovelaceValueOf $ gpAmount gp
ledgerTx <- submitTxConstraints typedValidator tx
void $ awaitTxConfirmed $ getCardanoTxId ledgerTx
logInfo @String $ printf "made a gift of %d lovelace to %s with deadline %s"
(gpAmount gp)
(show $ gpBeneficiary gp)
(show $ gpDeadline gp)
How would I pass in the necessary information to this to test if it runs or not.
Basically what I am asking is how do i just start hacking on Plutus. Just run some of the functions that Plutus have ,pass in some parameters , and see what it returns. I know i can run it in GHCI but I feel like I have some gaps in my knowledge and it is not connecting yet.