Skip to content

Commit

Permalink
Merge remote-tracking branch 'origin/master' into feat/inmemory-gnoland
Browse files Browse the repository at this point in the history
  • Loading branch information
gfanton committed Oct 11, 2023
2 parents f01ad76 + dce345f commit 676523e
Show file tree
Hide file tree
Showing 3 changed files with 21 additions and 25 deletions.
8 changes: 5 additions & 3 deletions .github/workflows/gnoland.yml
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,9 @@ jobs:
- _test.gnoland
- _test.gnokey
- _test.pkgs
#- _test.gnoweb # this test should be rewritten to run an inmemory localnode
# XXX: test broken, should be rewritten to run an inmemory localnode
# Re-add to makefile when fixed. Tracked here: https://github.com/gnolang/gno/issues/1222
#- _test.gnoweb
runs-on: ubuntu-latest
timeout-minutes: 15
steps:
Expand All @@ -76,7 +78,7 @@ jobs:
export LOG_DIR="${{ runner.temp }}/logs/test-${{ matrix.goversion }}-gnoland"
make ${{ matrix.args }}
- name: Upload Test Log
if: always()
if: always()
uses: actions/upload-artifact@v3
with:
name: logs-test-gnoland-go${{ matrix.goversion }}
Expand All @@ -99,7 +101,7 @@ jobs:
uses: codecov/codecov-action@v3
with:
directory: ${{ runner.temp }}/coverage
token: ${{ secrets.CODECOV_TOKEN }}
token: ${{ secrets.CODECOV_TOKEN }}
fail_ci_if_error: ${{ github.repository == 'gnolang/gno' }}

docker-integration:
Expand Down
4 changes: 3 additions & 1 deletion gno.land/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,9 @@ fmt:
########################################
# Test suite
.PHONY: test
test: _test.gnoland _test.gnoweb _test.gnokey _test.pkgs
test: _test.gnoland _test.gnokey _test.pkgs
# XXX: _test.gnoweb is currently disabled. If fixed, re-enable here and in CI.
# https://github.com/gnolang/gno/issues/1222

GOTEST_FLAGS ?= -v -p 1 -timeout=30m

Expand Down
34 changes: 13 additions & 21 deletions gno.land/pkg/integration/testdata/gnokey.txtar
Original file line number Diff line number Diff line change
Expand Up @@ -6,27 +6,19 @@ gnoland start

## test1 account should be available on default
gnokey query auth/accounts/${USER_ADDR_test1}
cmp stdout gnokey-query-valid.stdout.golden
cmp stderr gnokey-query-valid.stderr.golden
stdout 'height: 0'
stdout 'data: {'
stdout ' "BaseAccount": {'
stdout ' "address": "g1jg8mtutu9khhfwc4nxmuhcpftf0pajdhfvsqf5",'
stdout ' "coins": "[0-9]*ugnot",' # dynamic
stdout ' "public_key": null,'
stdout ' "account_number": "0",'
stdout ' "sequence": "0"'
stdout ' }'
stdout '}'
! stderr '.+' # empty

## invalid gnokey command should raise an error
! gnokey query foo/bar
cmp stdout gnokey-query-invalid.stdout.golden
cmp stderr gnokey-query-invalid.stderr.golden

-- gnokey-query-valid.stdout.golden --
height: 0
data: {
"BaseAccount": {
"address": "g1jg8mtutu9khhfwc4nxmuhcpftf0pajdhfvsqf5",
"coins": "9999892000000ugnot",
"public_key": null,
"account_number": "0",
"sequence": "0"
}
}
-- gnokey-query-valid.stderr.golden --
-- gnokey-query-invalid.stdout.golden --
Log:
-- gnokey-query-invalid.stderr.golden --
"gnokey" error: unknown request error
stdout 'Log:'
stderr '"gnokey" error: unknown request error'

0 comments on commit 676523e

Please sign in to comment.