From 1196b834ee930d87ed206a31a71bae1768825820 Mon Sep 17 00:00:00 2001 From: shawn Date: Wed, 12 Jul 2023 11:44:14 -0700 Subject: [PATCH] verify as raw byte array values for js contract invoke values (#67) --- features/dapp_develop/dapp_develop.feature | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/features/dapp_develop/dapp_develop.feature b/features/dapp_develop/dapp_develop.feature index 81383ba..fabb883 100644 --- a/features/dapp_develop/dapp_develop.feature +++ b/features/dapp_develop/dapp_develop.feature @@ -9,10 +9,11 @@ Scenario Outline: DApp developer compiles, installs, deploys and invokes a contr And I used cli to deploy contract / by installed hash using my secret key When I invoke function on with request parameters from tool using my secret key Then The result should be - +# Note, the NODEJS verification value for hello world response of ScVal(ScVec(Sym("Hello"),Sym("Aloha"))) +# is stringified Uint8Array for each Sym value per js scValToNative conversion. Examples: | Tool | ContractExampleSubPath | ContractName | ContractCompiledFileName | FunctionName | FunctionParams | Result | - | NODEJS | hello_world | soroban-hello-world-contract | soroban_hello_world_contract.wasm | hello | Aloha | ["Hello","Aloha"] | + | NODEJS | hello_world | soroban-hello-world-contract | soroban_hello_world_contract.wasm | hello | Aloha | [{"0":72,"1":101,"2":108,"3":108,"4":111},{"0":65,"1":108,"2":111,"3":104,"4":97}] | | CLI | hello_world | soroban-hello-world-contract | soroban_hello_world_contract.wasm | hello | --to=Aloha | ["Hello","Aloha"] | | NODEJS | increment | soroban-increment-contract | soroban_increment_contract.wasm | increment | | 1 | | CLI | increment | soroban-increment-contract | soroban_increment_contract.wasm | increment | | 1 | @@ -27,10 +28,11 @@ Scenario Outline: DApp developer compiles, deploys and invokes a contract When I invoke function on with request parameters from tool using my secret key Then The result should be And The result should be to receive contract events and diagnostic events for from - +# Note, the NODEJS verification value for hello world response of ScVal(ScVec(Sym("Hello"),Sym("Aloha"))) +# is stringified Uint8Array for each Sym value per js scValToNative conversion. Examples: | Tool | ContractExampleSubPath | ContractName | ContractCompiledFileName | FunctionName | FunctionParams | Result | EventCount | DiagEventCount | - | NODEJS | hello_world | soroban-hello-world-contract | soroban_hello_world_contract.wasm | hello | Aloha | ["Hello","Aloha"] | 0 | 1 | + | NODEJS | hello_world | soroban-hello-world-contract | soroban_hello_world_contract.wasm | hello | Aloha | [{"0":72,"1":101,"2":108,"3":108,"4":111},{"0":65,"1":108,"2":111,"3":104,"4":97}] | 0 | 1 | | CLI | hello_world | soroban-hello-world-contract | soroban_hello_world_contract.wasm | hello | --to=Aloha | ["Hello","Aloha"] | 0 | 1 | | NODEJS | increment | soroban-increment-contract | soroban_increment_contract.wasm | increment | | 1 | 0 | 1 | | CLI | increment | soroban-increment-contract | soroban_increment_contract.wasm | increment | | 1 | 0 | 1 |