Skip to content

Commit

Permalink
ci: fix tests
Browse files Browse the repository at this point in the history
  • Loading branch information
afsardo committed May 19, 2023
1 parent ab19a74 commit e40b6b8
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 5 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ jobs:
- name: Build package
run: make build

- name: Setup Node
- name: Setup node
uses: actions/setup-node@v3
with:
node-version: 16.x
Expand Down
10 changes: 8 additions & 2 deletions test/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -177,8 +177,14 @@ async function stable_swap_test(client: CosmWasmClient) {
)
);
assert(
stable_result.return_amount === simulation.return_amount &&
stable_result.spread_amount === simulation.spread_amount &&
BigNumber(stable_result.return_amount)
.minus(simulation.return_amount)
.abs()
.toNumber() <= 1 &&
BigNumber(stable_result.commission_amount)
.minus(simulation.commission_amount)
.abs()
.toNumber() <= 1 &&
stable_result.commission_amount === simulation.commission_amount
);
}
Expand Down
4 changes: 2 additions & 2 deletions test/package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit e40b6b8

Please sign in to comment.