Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix web3-gateway to use iroha addresses everywhere and add integration testing for the onchain module #60

Merged
merged 10 commits into from
Feb 10, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
55 changes: 55 additions & 0 deletions .github/workflows/test-onchain-module.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,55 @@
name: onchain-module
on:
pull_request:
paths:
- "docker/**"
- "onchain-module/**"
- ".github/workflows/test-onchain-module.yml"

jobs:
test-integration:
name: test-integration
runs-on: ubuntu-20.04
steps:
- name: Set up Go 1.16
uses: actions/setup-go@v2
with:
go-version: 1.16
- name: Set up Node.js 16
uses: actions/setup-node@v2
with:
node-version: '16'
- uses: actions/checkout@v2
- name: Cache go modules
uses: actions/cache@v2
with:
path: |
~/.cache/go-build
~/go/pkg/mod
key: ${{ runner.os }}-go-${{ hashFiles('**/go.sum') }}
restore-keys: |
${{ runner.os }}-go-
- name: Cache node modules
uses: actions/cache@v2
env:
cache-name: cache-node-modules
with:
path: |
${{ github.workspace }}/onchain-module/node_modules
key: ${{ runner.os }}-onchain-module-integration-${{ hashFiles('onchain-module/tests/e2e/contracts/package-lock.json') }}
restore-keys: |
${{ runner.os }}-onchain-module-integration-
- name: Run docker-compose
run: docker compose up -d iroha-node0 iroha-node0-postgres iroha-web3-gateway0
- name: Download NPM dependency
working-directory: onchain-module
run: |
npm install
- name: Migrate Contracts
working-directory: onchain-module
run: |
npm run migrate
- name: Run Integration Test for onchain-module
working-directory: onchain-module
run: |
make integration-test
8 changes: 4 additions & 4 deletions .github/workflows/test-web3-gateway.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,10 +16,10 @@ jobs:
uses: actions/setup-go@v2
with:
go-version: 1.16
- name: Set up Node.js 12
- name: Set up Node.js 16
uses: actions/setup-node@v2
with:
node-version: '12'
node-version: '16'
- uses: actions/checkout@v2
- name: Cache go modules
uses: actions/cache@v2
Expand All @@ -37,9 +37,9 @@ jobs:
with:
path: |
${{ github.workspace }}/web3-gateway/tests/e2e/contracts/node_modules
key: ${{ runner.os }}-web3-gateway-e2e-${{ hashFiles('web3-gateway/tests/e2e/contracts/package-lock.json') }}
key: ${{ runner.os }}-web3-gateway-${{ hashFiles('web3-gateway/tests/e2e/contracts/package-lock.json') }}
restore-keys: |
${{ runner.os }}-web3-gateway-e2e-
${{ runner.os }}-web3-gateway-
- name: Run docker-compose
run: docker compose up -d iroha-node0 iroha-node0-postgres iroha-web3-gateway0
- name: Download NPM dependency
Expand Down
1 change: 1 addition & 0 deletions docker/config/node0/[email protected]
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
a6924c9781c46df18c05545735f127eaf788a60816a7aeb9d5e928460b51cb2f
1 change: 1 addition & 0 deletions docker/config/node0/[email protected]
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
8884f3631f6435bce86b0da6868b10370441364ed225b3892e598cea96508323
1 change: 1 addition & 0 deletions docker/config/node0/[email protected]
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
f66c1f19a52bf2955d00bf050793a80056ccfa6237b46f4d7d3a9e20af669c29
1 change: 1 addition & 0 deletions docker/config/node0/[email protected]
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
d36b4f4de888a7b60681e405247131ba053faee3286cd5db8467535f58ef3202
Loading