-
Notifications
You must be signed in to change notification settings - Fork 212
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* PRT-655 Implement beta sdk test * Fix lint * Fix sdk test * Tidy pairing.go * Fix issues after merge * Enable e2e * Fix lint * Add rest and tendermint tests * Tidy tests * Add badge server sdk tests * Fix linter * Add env for sdk tests * Remove unnecessary logs * Fix console rog for errors in sdk e2e tests * Seperate e2e to 2 github actions * Fix linter * Fix test seperation * Add readme and fix log path * change go version to 1.20.5 * fixing log propagation --------- Co-authored-by: Ran Mishael <[email protected]>
- Loading branch information
1 parent
6bdc35f
commit 73911d6
Showing
20 changed files
with
897 additions
and
216 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -3,15 +3,15 @@ name: Lava E2E Tests | |
on: [pull_request] | ||
|
||
jobs: | ||
go: | ||
test-protocol-e2e: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v3 | ||
with: | ||
fetch-depth: '0' | ||
- uses: actions/setup-go@v3 | ||
with: | ||
go-version: 1.19.11 | ||
go-version: 1.20.5 | ||
|
||
# Install Ignite | ||
- name: ignite install | ||
|
@@ -61,71 +61,201 @@ jobs: | |
### Run Lava E2E Tests IGNITE VERSION:0.22.1 | ||
###################################################### | ||
- name: Run Lava E2E Tests IGNITE VERSION:0.22.1 -timeout 1200s | ||
run: go test ./testutil/e2e/ -v -timeout 1200s # 20mins | ||
run: go test ./testutil/e2e/ -run ^TestLavaProtocol$ -v -timeout 1200s # 20mins | ||
|
||
- name: Stake Lava All Logs | ||
if: always() | ||
run: cat testutil/e2e/logs/01_stakeLava.log | ||
run: cat testutil/e2e/protocolLogs/01_stakeLava.log | ||
|
||
- name: Stake Lava Error Only Logs | ||
if: always() | ||
continue-on-error: true | ||
run: cat testutil/e2e/logs/01_stakeLava_errors.log | ||
run: cat testutil/e2e/protocolLogs/01_stakeLava_errors.log | ||
|
||
- name: head -n 300 JSON Proxy Logs | ||
if: always() | ||
run: head -n 300 testutil/e2e/logs/02_jsonProxy.log | ||
run: head -n 300 testutil/e2e/protocolLogs/02_jsonProxy.log | ||
|
||
- name: tail -n 300 JSON Proxy Logs | ||
if: always() | ||
run: tail -n 300 testutil/e2e/logs/02_jsonProxy.log | ||
run: tail -n 300 testutil/e2e/protocolLogs/02_jsonProxy.log | ||
|
||
- name: JSON Proxy Error Only Logs | ||
if: always() | ||
continue-on-error: true | ||
run: cat testutil/e2e/logs/02_jsonProxy_errors.log | ||
run: cat testutil/e2e/protocolLogs/02_jsonProxy_errors.log | ||
|
||
- name: JSON Provider All Logs | ||
if: always() | ||
run: grep "" testutil/e2e/logs/03_EthProvider* --exclude="*errors*" | ||
run: grep "" testutil/e2e/protocolLogs/03_EthProvider* --exclude="*errors*" | ||
|
||
- name: JSON Provider Error Only Logs | ||
if: always() | ||
continue-on-error: true | ||
run: grep "" testutil/e2e/logs/03_EthProvider* --include="*errors*" | ||
run: grep "" testutil/e2e/protocolLogs/03_EthProvider* --include="*errors*" | ||
|
||
- name: JSON Consumer All Logs | ||
if: always() | ||
run: grep "" testutil/e2e/logs/04_jsonConsumer* --exclude="*errors*" | ||
run: grep "" testutil/e2e/protocolLogs/04_jsonConsumer* --exclude="*errors*" | ||
|
||
- name: JSON Consumer Error Only Logs | ||
if: always() | ||
continue-on-error: true | ||
run: grep "" testutil/e2e/logs/04_jsonConsumer* --include="*errors*" | ||
run: grep "" testutil/e2e/protocolLogs/04_jsonConsumer* --include="*errors*" | ||
|
||
- name: Lava Provider All Logs | ||
if: always() | ||
run: grep "" testutil/e2e/logs/05_LavaProvider* --exclude="*errors*" | ||
run: grep "" testutil/e2e/protocolLogs/05_LavaProvider* --exclude="*errors*" | ||
|
||
- name: Lava Provider Error Only Logs | ||
if: always() | ||
continue-on-error: true | ||
run: grep "" testutil/e2e/logs/05_LavaProvider* --include="*errors*" | ||
run: grep "" testutil/e2e/protocolLogs/05_LavaProvider* --include="*errors*" | ||
|
||
- name: Lava over Lava All Logs | ||
if: always() | ||
run: cat testutil/e2e/logs/07_lavaOverLava.log | ||
run: cat testutil/e2e/protocolLogs/07_lavaOverLava.log | ||
|
||
- name: Lava over Lava Error Only Logs | ||
if: always() | ||
continue-on-error: true | ||
run: cat testutil/e2e/logs/07_lavaOverLava_errors.log | ||
run: cat testutil/e2e/protocolLogs/07_lavaOverLava_errors.log | ||
|
||
- name: RPCConsumer Consumer All Logs | ||
if: always() | ||
run: grep "" testutil/e2e/logs/06_RPCConsumer* --exclude="*errors*" | ||
run: grep "" testutil/e2e/protocolLogs/06_RPCConsumer* --exclude="*errors*" | ||
|
||
- name: RPCConsumer Consumer Error Only Logs | ||
if: always() | ||
continue-on-error: true | ||
run: grep "" testutil/e2e/logs/06_RPCConsumer* --include="*errors*" | ||
run: grep "" testutil/e2e/protocolLogs/06_RPCConsumer* --include="*errors*" | ||
test-sdk-e2e: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v3 | ||
with: | ||
fetch-depth: '0' | ||
- uses: actions/setup-go@v3 | ||
with: | ||
go-version: 1.20.5 | ||
|
||
# Install Ignite | ||
- name: ignite install | ||
run: git clone --depth 1 --branch v0.26.1 https://github.com/ignite/cli && cd cli && make install | ||
# run: curl https://get.ignite.com/cli! | bash | ||
- name: ignite version | ||
run: ignite version | ||
# - name: starport install | ||
# run: curl https://get.starport.network/[email protected]! | bash | ||
# - name: starport version | ||
# run: starport version | ||
|
||
# Setup Paths | ||
- name: home | ||
run: pwd && ls -l | ||
- name: ls usr | ||
run: ls -l /home/runner/work/lava/lava | ||
- name: cp lava | ||
run: cp -r ~/work/lava/lava ~/go/lava | ||
- name: export PATH | ||
run: export PATH=$PATH:/go:/go/bin:$(go env GOPATH)/bin:/usr/local:`pwd`:/home/runner/work/lava/lava/ | ||
# - name: export | ||
# run: export PATH=$PATH:/go/lava | ||
- name: export GOPATH | ||
run: export GOPATH=$GOPATH:$(go env GOPATH):/go:/go/lava:/usr/local:`pwd` | ||
- name: export LAVA | ||
run: export LAVA=/home/runner/work/lava/lava | ||
- name: go env | ||
run: go env | ||
- name: pwd | ||
run: pwd | ||
- name: tree | ||
run: tree | ||
- name: ls -l | ||
run: ls -l | ||
|
||
# Pre-build with ignite | ||
- name: ignite build | ||
uses: nick-fields/retry@v2 | ||
with: | ||
max_attempts: 3 | ||
retry_on: error | ||
timeout_minutes: 20 | ||
command: ignite chain build -v | ||
|
||
# Install Node.js | ||
- name: Setup Node.js environment | ||
uses: actions/setup-node@v3 | ||
with: | ||
node-version: 20 | ||
|
||
# Install dependencies and build | ||
- name: Install dependencies and build | ||
run: | | ||
cd ecosystem/lava-sdk | ||
npm install | ||
npm run build | ||
###################################################### | ||
### Run Lava E2E Tests IGNITE VERSION:0.22.1 | ||
###################################################### | ||
- name: Run Lava E2E Tests IGNITE VERSION:0.22.1 -timeout 1200s | ||
run: go test ./testutil/e2e/ -run ^TestLavaSDK -v -timeout 1200s # 20mins | ||
|
||
- name: Stake Lava All Logs | ||
if: always() | ||
run: cat testutil/e2e/sdkLogs/01_stakeLava.log | ||
|
||
- name: Stake Lava Error Only Logs | ||
if: always() | ||
continue-on-error: true | ||
run: cat testutil/e2e/sdkLogs/01_stakeLava_errors.log | ||
|
||
- name: head -n 300 JSON Proxy Logs | ||
if: always() | ||
run: head -n 300 testutil/e2e/sdkLogs/02_jsonProxy.log | ||
|
||
- name: tail -n 300 JSON Proxy Logs | ||
if: always() | ||
run: tail -n 300 testutil/e2e/sdkLogs/02_jsonProxy.log | ||
|
||
- name: JSON Proxy Error Only Logs | ||
if: always() | ||
continue-on-error: true | ||
run: cat testutil/e2e/sdkLogs/02_jsonProxy_errors.log | ||
|
||
- name: JSON Provider All Logs | ||
if: always() | ||
run: grep "" testutil/e2e/sdkLogs/03_EthProvider* --exclude="*errors*" | ||
|
||
- name: JSON Provider Error Only Logs | ||
if: always() | ||
continue-on-error: true | ||
run: grep "" testutil/e2e/sdkLogs/03_EthProvider* --include="*errors*" | ||
|
||
- name: Lava Provider All Logs | ||
if: always() | ||
run: grep "" testutil/e2e/sdkLogs/05_LavaProvider* --exclude="*errors*" | ||
|
||
- name: Lava Provider Error Only Logs | ||
if: always() | ||
continue-on-error: true | ||
run: grep "" testutil/e2e/sdkLogs/05_LavaProvider* --include="*errors*" | ||
|
||
- name: Badge Server All Logs | ||
if: always() | ||
run: grep "" testutil/e2e/sdkLogs/01_BadgeServer* --exclude="*errors*" | ||
|
||
- name: Badge Server Error Only Logs | ||
if: always() | ||
continue-on-error: true | ||
run: grep "" testutil/e2e/sdkLogs/01_BadgeServer* --include="*errors*" | ||
|
||
- name: Lava SDK All Logs | ||
if: always() | ||
run: grep "" testutil/e2e/sdkLogs/01_sdkTest* --exclude="*errors*" | ||
|
||
- name: Lava SDK Error Only Logs | ||
if: always() | ||
continue-on-error: true | ||
run: grep "" testutil/e2e/sdkLogs/01_sdkTest* --include="*errors*" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.