Questions tagged [emulator]
The emulator tag has no usage guidance.
5 questions
0
votes
1
answer
29
views
Why is writeToScript reporting that my script costs 0 resources?
I have the following minting script:
{-# INLINABLE verify_mint #-}
script :: () -> V2.ScriptContext -> Bool
script () _ = (3::Integer) == 2+1
and the following off-chain code to mint a token:
...
0
votes
1
answer
46
views
Submit transactions to the blockchain in Plutus
Currently my workflow is like this:
write a validator script in Plutus
test the script in by creating functions/endpoints to submit transactions to Plutus.Trace (Emulator)
if the test goes well, I ...
0
votes
1
answer
30
views
suppress errors in trace emulator
I would like to suppress this error. How can I do that ?
Slot 00013: *** CONTRACT LOG: "PassingTest [TEST_TAG:3] -- caught error: WalletContractError (ValidationError (ScriptFailure (...
0
votes
1
answer
57
views
PlutusV2: Error when spending script output
This is how I spend script's utxos with the Emulator. This one from this example.
grab :: forall w s e. AsContractError e => Contract w s e ()
grab = do
utxos <- utxosAt scrAddress ...
0
votes
1
answer
28
views
Custom currency error: Cannot build the initial state: Tag "toCardanoPolicyId"
I try to set an initial state of the emulator like so:
test :: IO ()
test = runEmulatorTraceIO' def emCfg myTrace
where
dist = Map.fromList [ (senderWallet, Ada.lovelaceValueOf 100_000_000)
...