diff options
| author | Roman Smrž <roman.smrz@seznam.cz> | 2026-09-07 21:39:17 +0200 |
|---|---|---|
| committer | Roman Smrž <roman.smrz@seznam.cz> | 2026-09-09 22:09:21 +0200 |
| commit | a271cccc66698754612a46164ecbea66c4296d43 (patch) | |
| tree | 6aef002ae9da55a44129f2bbea026a403b93d841 | |
| parent | 4cb55936d53e0d1c49881bc3f9ffb4e3c5dbf65c (diff) | |
(test) Test: commands working with custom shared state
| -rw-r--r-- | state.et | 26 |
1 files changed, 26 insertions, 0 deletions
diff --git a/state.et b/state.et new file mode 100644 index 0000000..ab8703d --- /dev/null +++ b/state.et @@ -0,0 +1,26 @@ +module state + +import common + +test SharedStateLocal: + spawn as p + with p: + send "create-identity Device Owner" + expect /create-identity-done ref $refpat extref ($refpat).*/ capture device + send "identity-info $device" + expect /identity-info ref $device base $refpat owner ($refpat).*/ capture owner + + send "shared-state-val-get 0c6c1fe0-f2d7-4891-926b-c332449f7871" + expect /shared-state-val-get 0c6c1fe0-f2d7-4891-926b-c332449f7871 $owner/ + + for i in [ 1 .. 10 ]: + send: + "store rec" + "i:i $i" + "" + expect /store-done ($refpat)/ capture r + + send "shared-state-val-set ffffffff-0000-0000-0000-000000000001 $r" + + send "shared-state-val-get ffffffff-0000-0000-0000-000000000001" + expect /shared-state-val-get ffffffff-0000-0000-0000-000000000001 $r/ |