-
Notifications
You must be signed in to change notification settings - Fork 11
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
1 changed file
with
49 additions
and
0 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,49 @@ | ||
name: Tests | ||
|
||
env: | ||
DEVNET_SHA: "c6ffb99" | ||
|
||
on: | ||
push: | ||
branches: | ||
- main | ||
- develop | ||
pull_request: | ||
branches: | ||
- main | ||
- develop | ||
workflow_dispatch: | ||
|
||
jobs: | ||
run-tests: | ||
|
||
# This job runs on Ubuntu-latest, but you can choose other runners if needed | ||
runs-on: ubuntu-latest | ||
|
||
strategy: | ||
matrix: | ||
node-version: [16.x, 18.x] # Define Node.js versions to test against | ||
|
||
# Steps represent a sequence of tasks that will be executed as part of the job | ||
steps: | ||
- uses: actions/checkout@v3 # Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it | ||
|
||
- uses: actions-rust-lang/setup-rust-toolchain@v1 | ||
|
||
- name: Use Node.js ${{ matrix.node-version }} | ||
uses: actions/setup-node@v2 | ||
with: | ||
node-version: ${{ matrix.node-version }} | ||
cache: 'yarn' # Caches dependencies to speed up workflows | ||
|
||
- name: Install dependencies | ||
run: yarn install # Installs dependencies defined in package.json | ||
|
||
- name: Install Devnet | ||
run: cargo install --locked --git https://github.com/0xSpaceShard/starknet-devnet-rs.git --rev ${{ env.DEVNET_SHA }} | ||
|
||
- name: Run Devnet | ||
run: starknet-devnet --seed 0 | ||
|
||
- name: Run tests | ||
run: yarn test # Runs your test script defined in package.json |