From 45575cae961953cc1cb3a3915d1d0676207b0717 Mon Sep 17 00:00:00 2001 From: KtorZ Date: Thu, 16 Mar 2023 18:40:50 +0100 Subject: [PATCH] Fix 'run' script and re-generate blueprint for scenario 077. --- examples/acceptance_tests/077/plutus.json | 85 ++++++++----------- .../acceptance_tests/077/validators/spend2.ak | 3 +- examples/acceptance_tests/run | 2 +- 3 files changed, 38 insertions(+), 52 deletions(-) diff --git a/examples/acceptance_tests/077/plutus.json b/examples/acceptance_tests/077/plutus.json index 4cacceb9..2454a18e 100644 --- a/examples/acceptance_tests/077/plutus.json +++ b/examples/acceptance_tests/077/plutus.json @@ -5,67 +5,52 @@ "plutusVersion": "v2" }, "validators": [ - { - "title": "spend2.backtrace", - "datum": { - "title": "Unit", - "description": "The nullary constructor.", - "schema": { - "anyOf": [ - { - "dataType": "constructor", - "index": 0, - "fields": [] - } - ] - } - }, - "redeemer": { - "title": "Unit", - "description": "The nullary constructor.", - "schema": { - "anyOf": [ - { - "dataType": "constructor", - "index": 0, - "fields": [] - } - ] - } - }, - "compiledCode": "59016e010000323232323232323232323222253330063232323232324a26464640026028002600c64a66601a66e1d20003010375400220022a6601e9212a4578706563746564206f6e20696e636f727265637420636f6e7374727563746f722076617269616e742e00163300337586600a600c6600a600c0029000240084944018c010c94ccc02ccdc3a4000601c6ea8004400454cc03524012a4578706563746564206f6e20696e636f727265637420636f6e7374727563746f722076617269616e742e001633001375866006600866006600800a9000240084944c0040048894ccc0400084cdd2a400497ae013232533300d300300213374a90001980980125eb804ccc01401400400cc05000cc04800888c8ccc0040052000003222333300c3370e008004026466600800866e0000d200230150010012300b37540022930b180080091129998048010a4c26600a600260160046660060066018004002ae695cdab9c5573aaae7955cfaba05742ae881", - "hash": "546dac827307d09062352c0f50a35bfd5bcfe64233ea06d791f754ea" - }, { "title": "spend.staking", "datum": { - "title": "Unit", - "description": "The nullary constructor.", + "title": "_datum", "schema": { - "anyOf": [ - { - "dataType": "constructor", - "index": 0, - "fields": [] - } - ] + "$ref": "#/definitions/Void" } }, "redeemer": { - "title": "Unit", - "description": "The nullary constructor.", + "title": "_redeemer", "schema": { - "anyOf": [ - { - "dataType": "constructor", - "index": 0, - "fields": [] - } - ] + "$ref": "#/definitions/Void" } }, "compiledCode": "5904a1010000323232323232323232323222253330063232323232323232323232323232323232323232323232323375e6e98008dd300099980a1bac33016301733016301701848001200422533301f3375e66030603200490000020998061bab3301830190024800800440052f5bded8c06660266eb0cc054c058cc054c05805d200048000894ccc078cdd79980b980c1980b980c0012400490000018998059bab33017301833017301800248009200200110014bd6f7b6301980a180a800a4000604200260420026024002603c002602064a66602e66e1d2000301a375400220022a660329212a4578706563746564206f6e20696e636f727265637420636f6e7374727563746f722076617269616e742e00163232330013758660226024660226024026900024000466ebccc048c04c00520000043001001222533301e00213374a900125eb804c8c94ccc06cc00c0084cdd2a40006604200497ae0133300500500100330220033020002301c001300e3253330153370e9001180c1baa001100115330174912a4578706563746564206f6e20696e636f727265637420636f6e7374727563746f722076617269616e742e00163300d300e00f4800888c8004cccc8888cccc03001000c008004008004888c94ccc064c94ccc07c0045288a5000113374a900125eb804cdd2a40006603e6e980052f5c066664444666601600800600400200400244464a66603866e1c005200013374a900125eb804cdd2a4000660446ea00052f5c066e0000800401800c894ccc050cdc8001000899ba5480012f5c02a66602866e3c0080044cdd2a400497ae013374a900225eb80c004004888894ccc068010400c4c8c8c8c8ccccc02402400cccccc02801c004008018014018014dd7180d8019bad301b002301e005301c0043001001222222533301900513301a337606ea4010dd4001a5eb7bdb1804c8c8c8c94ccc060cdd79980280400099ba5480012f5c026603c66ec0dd48041ba8007009153330183371e01000226464a66603466e1c00520001323233022337606ea4030dd40008039bad302200130140021005301c375400266600c01000e00426603c66ec0dd48009ba800233333300a00a003008007006005375c60340066eb4c068008c074018c06c014c004004888894ccc058010400c4c8c8c8c8ccccc02402400cccccc02801c004008018014018014dd7180b8019bab3017002301a005301800430010012222225333015005133016337606ea4010dd3001a5eb7bdb1804c8c8c8c94ccc050cdd79980280400099ba5480012f5c026603466ec0dd48041ba6007009153330143371e01000226464a66602c66e1c0052000132323301e337606ea4030dd30008039bab301e001301000210053018375400266600c01000e00426603466ec0dd48009ba600233333300a00a003008007006005375c602c0066eacc058008c064018c05c014c00400488894ccc04400c40044c8c8cc010008cccc01801800401000cc054010c04c00c88c8ccc0040052000003222333300c3370e008004026466600800866e0000d200230150010012300b37540022930b180080091129998048010a4c26600a600260160046660060066018004002ae695cdab9c5573aaae7955cfaba05742ae881", "hash": "f6448fb18db20c4da7590f743682d806a7e1ab9cccee75848885b22a" + }, + { + "title": "spend2.backtrace", + "datum": { + "title": "_datum", + "schema": { + "$ref": "#/definitions/Void" + } + }, + "redeemer": { + "title": "_redeemer", + "schema": { + "$ref": "#/definitions/Void" + } + }, + "compiledCode": "590109010000323232323232323232323222253330063232324a2600464a66601266e1d2000300c375400220022a660169212a4578706563746564206f6e20696e636f727265637420636f6e7374727563746f722076617269616e742e0016323233001375866006600866006600800a9000240084944c0040048894ccc0400084cdd2a400497ae013232533300d300300213374a90001980980125eb804ccc01401400400cc05000cc04800888c8ccc0040052000003222333300c3370e008004026466600800866e0000d200230150010012300b37540022930b180080091129998048010a4c26600a600260160046660060066018004002ae695cdab9c5573aaae7955cfaba05742ae881", + "hash": "a48c257b952e82673f9832cba28bf43833fddb1b02ec0aeabe25e338" } - ] + ], + "definitions": { + "Void": { + "title": "Unit", + "description": "The nullary constructor.", + "anyOf": [ + { + "dataType": "constructor", + "index": 0, + "fields": [] + } + ] + } + } } \ No newline at end of file diff --git a/examples/acceptance_tests/077/validators/spend2.ak b/examples/acceptance_tests/077/validators/spend2.ak index 612bd2a8..f9646a7d 100644 --- a/examples/acceptance_tests/077/validators/spend2.ak +++ b/examples/acceptance_tests/077/validators/spend2.ak @@ -12,4 +12,5 @@ validator backtrace { fn find_stuff(context) -> Output { expect Some(stuff) = list.find(context.transaction.outputs, fn(_) { True }) stuff -} \ No newline at end of file +} + diff --git a/examples/acceptance_tests/run b/examples/acceptance_tests/run index 2bbe07b4..748cdf8c 100755 --- a/examples/acceptance_tests/run +++ b/examples/acceptance_tests/run @@ -16,7 +16,7 @@ TARGET="$WORKDIR/$(basename $1)" TMP=$(mktemp) VALIDATORS=$(find $TARGET -type f -path "*validators/*.ak") -if [ -z $VALIDATORS ]; then +if [ -z "$VALIDATORS" ]; then RESULT=$(cargo run --quiet -- check $TARGET 2>$TMP) else RESULT=$(cargo run --quiet -- build $TARGET 2>$TMP)