-
Notifications
You must be signed in to change notification settings - Fork 65
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'main' of https://github.com/argentlabs/argent-contracts…
…-starknet-private into update
- Loading branch information
Showing
148 changed files
with
200,136 additions
and
2,855 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 @@ | ||
starknet-devnet-rs |
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 |
---|---|---|
@@ -1,3 +1,3 @@ | ||
BASE_URL=https://alpha4.starknet.io/ | ||
RPC_URL=http://127.0.0.1:5050 | ||
ADDRESS=0x000000000000000000000000000000000000000000000000000000000000000 | ||
PRIVATE_KEY=0x000000000000000000000000000000000000000000000000000000000000000 |
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 |
---|---|---|
@@ -1,9 +1,5 @@ | ||
name: Cairo CI | ||
|
||
env: | ||
ARCHIVE_LINK: https://github.com/starkware-libs/cairo/releases/download/v2.0.0/release-x86_64-unknown-linux-musl.tar.gz | ||
ARCHIVE_NAME: cairo.zip | ||
|
||
on: push | ||
|
||
jobs: | ||
|
@@ -12,47 +8,17 @@ jobs: | |
steps: | ||
- name: Step 1 - Check out main branch | ||
uses: actions/checkout@v3 | ||
|
||
- name: Step 2 - Downloading binaries | ||
run: curl -L -o $ARCHIVE_NAME $ARCHIVE_LINK | ||
|
||
- name: Step 3 - Unzipping binaries | ||
run: tar -xvf $ARCHIVE_NAME | ||
|
||
- name: Step 4 - Make binaries available | ||
run: echo "./cairo/bin" >> $GITHUB_PATH | ||
|
||
- name: Step 5 - Run all tests | ||
run: cairo-test --starknet ./contracts | ||
|
||
- name: Step 2 - Getting scarb | ||
uses: software-mansion/[email protected] | ||
- name: Step 3 - Testing | ||
run: scarb test | ||
|
||
format: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Step 1 - Check out main branch | ||
uses: actions/checkout@v3 | ||
|
||
- name: Step 2 - Downloading binaries | ||
run: curl -L -o $ARCHIVE_NAME $ARCHIVE_LINK | ||
|
||
- name: Step 3 - Unzipping binaries | ||
run: tar -xvf $ARCHIVE_NAME | ||
|
||
- name: Step 4 - Make binaries available | ||
run: echo "./cairo/bin" >> $GITHUB_PATH | ||
|
||
- name: Step 5 - Check formatting | ||
run: cairo-format --check --recursive ./contracts | ||
|
||
contract-approvers: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Step 1 - Check out main branch | ||
uses: actions/checkout@v3 | ||
|
||
- name: Step 2 - Install project | ||
run: yarn install --frozen-lockfile | ||
|
||
- name: Step 3 - Check approvers count | ||
run: yarn ts-node ./scripts/check-contract-approvers.ts 3 | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
- name: Step 2 - Getting scarb | ||
uses: software-mansion/[email protected] | ||
- name: Step 3 - Checking format | ||
run: scarb fmt --check |
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 |
---|---|---|
@@ -1,47 +1,47 @@ | ||
name: Integration CI | ||
|
||
env: | ||
ARCHIVE_LINK: https://github.com/starkware-libs/cairo/releases/download/v2.0.0/release-x86_64-unknown-linux-musl.tar.gz | ||
ARCHIVE_NAME: cairo_binaries.zip | ||
|
||
on: push | ||
|
||
jobs: | ||
tests: | ||
integration-tests: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Step 1 - Check out main branch | ||
- name: Check out main branch | ||
uses: actions/checkout@v3 | ||
|
||
- name: Step 2 - Install correct python version | ||
uses: actions/setup-python@v4 | ||
with: | ||
python-version: "3.9" | ||
cache: "pip" | ||
|
||
- name: Step 3 - Cloning repo | ||
run: make clone-cairo | ||
- name: Setup Scarb | ||
uses: software-mansion/[email protected] | ||
|
||
- name: Install project | ||
run: yarn install --frozen-lockfile | ||
|
||
- name: Step 4 - Downloading binaries, unzipping them and making them available | ||
working-directory: ./cairo | ||
- name: Start devnet in background | ||
run: | | ||
curl -L -o $ARCHIVE_NAME $ARCHIVE_LINK | ||
tar -xvf $ARCHIVE_NAME | ||
mkdir -p target/release | ||
mv cairo/bin/* target/release | ||
scarb run start-devnet & | ||
./scripts/wait-devnet-ready.sh | ||
- name: Run integration tests | ||
run: scarb --release build && tsc && yarn mocha tests-integration/*.test.ts --forbid-only --forbid-pending | ||
|
||
- name: Step 5 - Installing requirements | ||
run: pip3 install -r requirements.txt | ||
gas-report: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Check out main branch | ||
uses: actions/checkout@v3 | ||
|
||
- name: Step 6 - Start devnet in background | ||
- name: Setup Scarb | ||
uses: software-mansion/[email protected] | ||
|
||
- name: Install project | ||
run: yarn install --frozen-lockfile | ||
|
||
- name: Start devnet in background | ||
run: | | ||
make devnet & | ||
scarb run start-devnet & | ||
./scripts/wait-devnet-ready.sh | ||
- name: Step 7 - Run integrations tests | ||
run: | | ||
yarn install --frozen-lockfile | ||
make test-integration | ||
- name: Gas report | ||
run: scarb run profile --check | ||
|
||
format: | ||
runs-on: ubuntu-latest | ||
|
@@ -53,7 +53,7 @@ jobs: | |
run: yarn install --frozen-lockfile | ||
|
||
- name: Step 3 - Check correct formatting | ||
run: yarn format:check | ||
run: yarn prettier --check . | ||
|
||
lint: | ||
runs-on: ubuntu-latest | ||
|
@@ -65,4 +65,4 @@ jobs: | |
run: yarn install --frozen-lockfile | ||
|
||
- name: Step 3 - Check correct linting | ||
run: yarn lint:check | ||
run: yarn eslint . |
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 |
---|---|---|
@@ -0,0 +1 @@ | ||
18 |
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 |
---|---|---|
@@ -1,5 +1,8 @@ | ||
cairo | ||
contracts | ||
venv | ||
tests/fixtures | ||
target | ||
deployments/artifacts | ||
dist | ||
.github | ||
tests-integration/fixtures | ||
starknet-devnet-rs |
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 @@ | ||
scarb 2.4.3 |
Oops, something went wrong.