Skip to content

Commit dc33e85

Browse files
authored
Merge pull request #854 from LIT-Protocol/feature/jss-32-naga-sdk-add-rpc-env-var-for-e2e-and-artillery-tests
Feature/jss 32 naga sdk add rpc env var for e2e and artillery tests
2 parents 98c1f62 + 2fb80de commit dc33e85

File tree

164 files changed

+25948
-25622
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

164 files changed

+25948
-25622
lines changed

.github/workflows/ci.yml

Lines changed: 0 additions & 113 deletions
This file was deleted.

.github/workflows/e2e.yml

Lines changed: 60 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,60 @@
1+
name: E2E Tests
2+
3+
on:
4+
push:
5+
branches:
6+
- main
7+
- master
8+
- develop
9+
pull_request:
10+
env:
11+
LIT_STATUS_WRITE_KEY: ${{ secrets.LIT_STATUS_WRITE_KEY }}
12+
LIT_STATUS_BACKEND_URL: ${{ vars.LIT_STATUS_BACKEND_URL }}
13+
LIVE_MASTER_ACCOUNT: ${{ secrets.LIVE_MASTER_ACCOUNT }}
14+
LOCAL_MASTER_ACCOUNT: ${{ secrets.LOCAL_MASTER_ACCOUNT }}
15+
LOG_LEVEL: info
16+
17+
jobs:
18+
naga-e2e-tests:
19+
runs-on: ubuntu-latest
20+
environment: Health Check
21+
steps:
22+
- name: Checkout code
23+
uses: actions/checkout@v4
24+
with:
25+
fetch-depth: 1
26+
27+
- name: Setup Bun
28+
uses: oven-sh/setup-bun@v1
29+
with:
30+
bun-version: latest
31+
32+
- name: Install rust
33+
uses: actions-rs/toolchain@v1
34+
with:
35+
toolchain: stable
36+
override: true
37+
components: rust-std
38+
39+
- name: Install wasm-pack
40+
uses: jetli/[email protected]
41+
with:
42+
version: 'latest'
43+
44+
- name: Install Bun dependencies
45+
run: bun install
46+
47+
- name: Build project
48+
run: bun run build
49+
50+
- name: Run health check for naga-dev
51+
run: NETWORK=naga-dev bun run test:e2e all --timeout 5000000
52+
timeout-minutes: 10
53+
54+
- name: Run health check for naga-test
55+
run: NETWORK=naga-test bun run test:e2e all --timeout 5000000
56+
timeout-minutes: 10
57+
58+
- name: Run health check for naga-staging
59+
run: NETWORK=naga-staging bun run test:e2e all --timeout 5000000
60+
timeout-minutes: 10

.github/workflows/lint.yml

Lines changed: 15 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -4,27 +4,33 @@ on:
44
push:
55
branches:
66
- master
7+
- main
8+
- develop
79
jobs:
810
linter:
911
runs-on: ubuntu-latest
1012
timeout-minutes: 10
1113
steps:
1214
- name: Checkout repo
13-
uses: actions/checkout@v2
15+
uses: actions/checkout@v4
1416
with:
1517
fetch-depth: 0
16-
- name: Set up Node.js
17-
uses: actions/setup-node@v3
18+
19+
- name: Setup Bun
20+
uses: oven-sh/setup-bun@v1
1821
with:
19-
node-version: '18'
20-
cache: 'yarn'
22+
bun-version: latest
23+
2124
- name: Install rust
2225
uses: dtolnay/[email protected]
23-
- uses: jetli/[email protected]
26+
27+
- name: Install wasm-pack
28+
uses: jetli/[email protected]
2429
with:
25-
# Optional version of wasm-pack to install(eg. 'v0.9.1', 'latest')
2630
version: 'latest'
31+
2732
- name: Install project dependencies
28-
run: yarn install
33+
run: bun install
34+
2935
- name: Lint
30-
run: yarn nx format:check --all
36+
run: bun run nx format:check --all

AGENTS.md

Lines changed: 0 additions & 40 deletions
This file was deleted.

e2e/artillery/configs/pkp-sign.yml

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,26 +1,26 @@
11
config:
2-
target: "dummy"
2+
target: 'dummy'
33
phases:
44
# Over 60s, ramp up to creating 50 vusers per second
55
- duration: 60
66
arrivalRate: 5
77
# rampTo: 50
88
rampTo: 10
9-
name: "Ramp Up"
9+
name: 'Ramp Up'
1010
# Over 300s, create 50 vusers per second
1111
- duration: 300
1212
# arrivalRate: 50
1313
arrivalRate: 10
14-
name: "Sustained PKP Signing"
14+
name: 'Sustained PKP Signing'
1515
# Over 60s, ramp down to creating 5 vusers per second
1616
- duration: 60
1717
arrivalRate: 5
18-
name: "Ramp Down"
19-
processor: "../src/processors/multi-endpoints.ts"
18+
name: 'Ramp Down'
19+
processor: '../src/processors/multi-endpoints.ts'
2020

2121
scenarios:
22-
- name: "PKP Sign Stress Test"
22+
- name: 'PKP Sign Stress Test'
2323
weight: 100
2424
flow:
25-
- function: "runPkpSignTest"
26-
- think: 0.1
25+
- function: 'runPkpSignTest'
26+
- think: 0.1
Lines changed: 8 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,27 +1,26 @@
11
config:
2-
target: "dummy"
2+
target: 'dummy'
33
phases:
44
# Over 60s, ramp up to creating 50 vusers per second
55
- duration: 60
66
arrivalRate: 5
77
# rampTo: 50
88
rampTo: 10
9-
name: "Ramp Up"
9+
name: 'Ramp Up'
1010
# Over 300s, create 50 vusers per second
1111
- duration: 300
1212
# arrivalRate: 50
1313
arrivalRate: 10
14-
name: "Sustained Sign Session Key"
14+
name: 'Sustained Sign Session Key'
1515
# Over 60s, ramp down to creating 5 vusers per second
1616
- duration: 60
1717
arrivalRate: 5
18-
name: "Ramp Down"
19-
processor: "../src/processors/multi-endpoints.ts"
18+
name: 'Ramp Down'
19+
processor: '../src/processors/multi-endpoints.ts'
2020

2121
scenarios:
22-
- name: "Sign Session Key Stress Test"
22+
- name: 'Sign Session Key Stress Test'
2323
weight: 100
2424
flow:
25-
26-
- function: "runSignSessionKeyTest"
27-
- think: 0.1
25+
- function: 'runSignSessionKeyTest'
26+
- think: 0.1

0 commit comments

Comments
 (0)