Skip to content
This repository was archived by the owner on Jul 10, 2025. It is now read-only.

Commit 208067e

Browse files
authored
Fix failing tests in AquaVM (#207)
1 parent 1f5fa89 commit 208067e

File tree

4 files changed

+24
-5
lines changed

4 files changed

+24
-5
lines changed

.github/workflows/snapshot.yml

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,10 @@ on:
99
marine-js-version:
1010
description: "@fluencelabs/marine-js version"
1111
type: string
12+
ref:
13+
description: "git ref to checkout to"
14+
type: string
15+
default: "master"
1216
outputs:
1317
fluence-js-version:
1418
description: "@fluencelabs/fluence version"
@@ -35,6 +39,7 @@ jobs:
3539
uses: actions/checkout@v3
3640
with:
3741
repository: fluencelabs/fluence-js
42+
ref: ${{ inputs.ref }}
3843

3944
- uses: pnpm/[email protected]
4045
with:

.github/workflows/tests.yml

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,10 @@ on:
1313
marine-js-version:
1414
description: "@fluencelabs/marine-js version"
1515
type: string
16+
ref:
17+
description: "git ref to checkout to"
18+
type: string
19+
default: "master"
1620

1721
env:
1822
RUST_PEER_IMAGE: "${{ inputs.rust-peer-image }}"
@@ -59,6 +63,7 @@ jobs:
5963
uses: actions/checkout@v3
6064
with:
6165
repository: fluencelabs/fluence-js
66+
ref: ${{ inputs.ref }}
6267

6368
- name: Pull rust-peer image
6469
run: docker pull $RUST_PEER_IMAGE

packages/fluence-js/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@fluencelabs/fluence",
3-
"version": "0.27.1",
3+
"version": "0.27.2",
44
"description": "TypeScript implementation of Fluence Peer",
55
"main": "./dist/index.js",
66
"typings": "./dist/index.d.ts",

packages/fluence-js/src/__test__/integration/avm.spec.ts

Lines changed: 13 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -85,7 +85,10 @@ describe('Avm spec', () => {
8585
(call %init_peer_id% ("peer" "timeout") [1000 arg] $result)
8686
(call %init_peer_id% ("op" "identity") ["fast_result"] $result)
8787
)
88-
(call %init_peer_id% ("return" "return") [$result.$[0]])
88+
(seq
89+
(canon %init_peer_id% $result #result)
90+
(call %init_peer_id% ("return" "return") [#result.$[0]])
91+
)
8992
)
9093
)
9194
`;
@@ -121,13 +124,19 @@ describe('Avm spec', () => {
121124
(call "invalid_peer" ("op" "identity") ["never"] $ok_or_err)
122125
)
123126
(xor
124-
(match $ok_or_err.$[0] "timeout_msg"
125-
(ap "failed_with_timeout" $result)
127+
(seq
128+
(canon %init_peer_id% $ok_or_err #ok_or_err)
129+
(match #ok_or_err.$[0] "timeout_msg"
130+
(ap "failed_with_timeout" $result)
131+
)
126132
)
127133
(ap "impossible happened" $result)
128134
)
129135
)
130-
(call %init_peer_id% ("return" "return") [$result.$[0]])
136+
(seq
137+
(canon %init_peer_id% $result #result)
138+
(call %init_peer_id% ("return" "return") [#result.$[0]])
139+
)
131140
)
132141
)
133142
`;

0 commit comments

Comments
 (0)