Skip to content

Commit

Permalink
ci: bump devnet and remove sequencer
Browse files Browse the repository at this point in the history
  • Loading branch information
penovicp committed Dec 12, 2023
1 parent 6e6b02a commit 51e44a7
Show file tree
Hide file tree
Showing 6 changed files with 19 additions and 43 deletions.
10 changes: 2 additions & 8 deletions .github/workflows/_test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,15 +2,13 @@ name: _ Run Tests
on:
workflow_call:
inputs:
use-rpc-devnet:
use-devnet:
type: boolean
default: false
use-seq-devnet:
type: boolean
default: false
secrets:
TEST_PROVIDER_BASE_URL:
required: false
TEST_RPC_URL:
required: false
TEST_ACCOUNT_PRIVATE_KEY:
Expand All @@ -26,20 +24,16 @@ jobs:
# TODO - periodically check if conditional services are supported; https://github.com/actions/runner/issues/822
services:
devnet:
image: ${{ inputs.use-rpc-devnet && 'shardlabs/starknet-devnet-rs:0c82d023f35bb77c4b5f4afd885ab14e44b73130-amd-seed0' || inputs.use-seq-devnet && 'shardlabs/starknet-devnet:0.6.3-seed0' || '' }}
# image: ${{ (inputs.use-rpc-devnet || inputs.use-seq-devnet) && 'shardlabs/starknet-devnet:0.6.3-seed0' || '' }}
# image: shardlabs/starknet-devnet-rs:0c82d023f35bb77c4b5f4afd885ab14e44b73130-amd-seed0
image: ${{ (inputs.use-devnet) && 'shardlabs/starknet-devnet-rs:85495efb71a37ad3921c8986474b7e78a9a9f5fc-amd-seed0' || '' }}
ports:
- 5050:5050

env:
TEST_PROVIDER_BASE_URL: ${{ secrets.TEST_PROVIDER_BASE_URL }}
TEST_RPC_URL: ${{ secrets.TEST_RPC_URL }}
TEST_ACCOUNT_PRIVATE_KEY: ${{ secrets.TEST_ACCOUNT_PRIVATE_KEY }}
TEST_ACCOUNT_ADDRESS: ${{ secrets.TEST_ACCOUNT_ADDRESS }}

steps:
- run: echo ${{ secrets.TEST_PROVIDER_BASE_URL }}
- run: echo ${{ secrets.TEST_RPC_URL }}
- uses: actions/checkout@v3
- uses: actions/setup-node@v3
Expand Down
7 changes: 1 addition & 6 deletions .github/workflows/manual-tests-devnet.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,17 +7,12 @@ jobs:
strategy:
fail-fast: false
matrix:
name: [sequencer-devnet, rpc-devnet]
include:
- name: sequencer-devnet
TEST_PROVIDER_BASE_URL: http://127.0.0.1:5050/
- name: rpc-devnet
TEST_RPC_URL: http://127.0.0.1:5050/rpc

uses: ./.github/workflows/_test.yml
with:
use-rpc-devnet: ${{ matrix.TEST_RPC_URL != '' }}
use-seq-devnet: ${{ matrix.TEST_PROVIDER_BASE_URL != '' }}
use-devnet: ${{ matrix.TEST_RPC_URL != '' }}
secrets:
TEST_PROVIDER_BASE_URL: ${{ matrix.TEST_PROVIDER_BASE_URL }}
TEST_RPC_URL: ${{ matrix.TEST_RPC_URL }}
14 changes: 3 additions & 11 deletions .github/workflows/manual-tests-testnet.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,20 +5,12 @@ jobs:
tests:
name: Run test on ${{ matrix.name }}
strategy:
max-parallel: 1 # needed until we get a seperate account for the rpc provider, until then running them in parallel would result in a nonce issue
max-parallel: 1
matrix:
name: [sequencer-goerli, rpc-goerli]
include:
- name: sequencer-goerli
ENABLE_SEQUENCER: true
ENABLE_RPC: false
- name: rpc-goerli
ENABLE_SEQUENCER: false
ENABLE_RPC: true
name: [rpc-goerli]

uses: ./.github/workflows/_test.yml
secrets:
TEST_PROVIDER_BASE_URL: ${{ matrix.ENABLE_SEQUENCER && secrets.TEST_PROVIDER_BASE_URL || ''}}
TEST_RPC_URL: ${{ matrix.ENABLE_RPC && secrets.TEST_RPC_URL || ''}}
TEST_RPC_URL: ${{ secrets.TEST_RPC_URL }}
TEST_ACCOUNT_PRIVATE_KEY: ${{ secrets.TEST_ACCOUNT_PRIVATE_KEY }}
TEST_ACCOUNT_ADDRESS: ${{ secrets.TEST_ACCOUNT_ADDRESS }}
7 changes: 1 addition & 6 deletions .github/workflows/pr-push-dev.yml
Original file line number Diff line number Diff line change
Expand Up @@ -44,19 +44,14 @@ jobs:
strategy:
fail-fast: false
matrix:
name: [sequencer-devnet, rpc-devnet]
include:
- name: sequencer-devnet
TEST_PROVIDER_BASE_URL: http://127.0.0.1:5050/
- name: rpc-devnet
TEST_RPC_URL: http://127.0.0.1:5050/rpc

uses: ./.github/workflows/_test.yml
with:
use-rpc-devnet: ${{ matrix.TEST_RPC_URL != '' }}
use-seq-devnet: ${{ matrix.TEST_PROVIDER_BASE_URL != '' }}
use-devnet: ${{ matrix.TEST_RPC_URL != '' }}
secrets:
TEST_PROVIDER_BASE_URL: ${{ matrix.TEST_PROVIDER_BASE_URL }}
TEST_RPC_URL: ${{ matrix.TEST_RPC_URL }}

release:
Expand Down
14 changes: 3 additions & 11 deletions .github/workflows/pr-push-main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -38,21 +38,13 @@ jobs:
needs: [skip_check]
if: needs.skip_check.outputs.should_skip != 'true'
strategy:
max-parallel: 1 # needed until we get a seperate account for the rpc provider, until then running them in parallel would result in a nonce issue
max-parallel: 1
matrix:
name: [sequencer-goerli, rpc-goerli]
include:
- name: sequencer-goerli
ENABLE_SEQUENCER: true
ENABLE_RPC: false
- name: rpc-goerli
ENABLE_SEQUENCER: false
ENABLE_RPC: true
name: [rpc-goerli]

uses: ./.github/workflows/_test.yml
secrets:
TEST_PROVIDER_BASE_URL: ${{ matrix.ENABLE_SEQUENCER && secrets.TEST_PROVIDER_BASE_URL || ''}}
TEST_RPC_URL: ${{ matrix.ENABLE_RPC && secrets.TEST_RPC_URL || ''}}
TEST_RPC_URL: ${{ secrets.TEST_RPC_URL }}
TEST_ACCOUNT_PRIVATE_KEY: ${{ secrets.TEST_ACCOUNT_PRIVATE_KEY }}
TEST_ACCOUNT_ADDRESS: ${{ secrets.TEST_ACCOUNT_ADDRESS }}

Expand Down
10 changes: 9 additions & 1 deletion __tests__/schemas/provider.json
Original file line number Diff line number Diff line change
Expand Up @@ -203,7 +203,15 @@
]
},
"actual_fee": {
"type": "string"
"type": "object",
"properties": {
"amount": {
"type": "string"
},
"unit": {
"type": "string"
}
}
},
"status_data": {
"type": "string"
Expand Down

0 comments on commit 51e44a7

Please sign in to comment.