Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Updating main branch #1

Open
wants to merge 175 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
175 commits
Select commit Hold shift + click to select a range
bb29f86
Feat: Implement the functions in the `swap_pricing_utils` library (#446)
delaaxe Sep 25, 2023
c2cbb4e
Feat/position pricing utils (#412)
sparqet Sep 25, 2023
ac48e57
Feat: Completed Implementation of `role_store` contract. (#443)
ametel01 Sep 25, 2023
fad9f1d
feat: add `increase_order_utils` (#448)
ftupas Sep 25, 2023
ddad35d
Feat: implement decrease_position() (#419)
FabienCoutant Sep 26, 2023
c7c5606
Improve Error Messages and Update Semgrep Rules for CI (#453)
ametel01 Sep 27, 2023
2d89ea6
updated snforge version (#457)
sparqet Sep 27, 2023
242f688
Deposit_handler Contract (#450)
sparqet Sep 28, 2023
3e72af1
Added new deployment scripts (#461)
sparqet Sep 28, 2023
a179c55
Update to 0.7.1 snforge - move tests to `tests` folder (#462)
piotmag769 Sep 28, 2023
4039f5f
:busts_in_silhouette: Add @piotmag769 as a contributor
AbdelStark Sep 29, 2023
1c65d4b
implemented claim_fees and claim_ui_fees functions (#464)
sparqet Sep 29, 2023
db747e8
All deployment scripts for contracts (#467)
sparqet Sep 30, 2023
5cf0d67
Feat: using i128 in the `i128_values` attribute of `DataStore` struct…
eytanlvy Sep 30, 2023
4a426ca
Add missing information in the smart-contract-architecture and in sum…
axelizsak Oct 2, 2023
a4fd78c
Feat: Implement the function in the `market_utils` library. #1 (#459)
delaaxe Oct 2, 2023
33b3b05
feat: implement create_liquidation_order function (#437)
lambda-0x Oct 2, 2023
8b44be5
Feat/reader_utils (#469)
sparqet Oct 2, 2023
65f4b92
Feat/log data : Implemented the log data (#472)
Sk8erboi84 Oct 2, 2023
0bfe80c
👥 add Oak, ftupas and lambda-0x as contributors (#473)
Sk8erboi84 Oct 2, 2023
223005d
👥 Fixed contributors szie (#474)
Sk8erboi84 Oct 2, 2023
fc648b9
Feat: Implement the function in the market_utils library. #2 (#460)
eytanlvy Oct 3, 2023
b9698e4
feat: implement order_vault & placeholder for test (#475)
zarboq Oct 3, 2023
ca0e1a4
Adding Role admin check to the role-admin branch (#495)
dic0de Oct 4, 2023
55c97b4
feat: implement decrease_position_collateral_utils (#465)
zarboq Oct 4, 2023
7ac41fb
Feat: Implement the function in the market_utils library #3 (#463)
Tbelleng Oct 5, 2023
05c607a
test: Tests for deposit_vault (#496)
akhercha Oct 5, 2023
dff7447
test: Improve tests for referral_storage contract (#499)
akhercha Oct 6, 2023
bbfc862
test: Improve tests of referral_utils library. #483 (#498)
tevrat-aksoy Oct 6, 2023
3367de4
Implementing StrictBank functions and tests (#426)
VictorONN Oct 6, 2023
7254124
✨ execute_deposit_utils functions (#449)
kasteph Oct 8, 2023
e8b6220
Feat: Adding a Contirbutor profil (#501)
Tbelleng Oct 8, 2023
f0bbf88
test: Added tests for record_transfer_in (#502)
akhercha Oct 8, 2023
8315c42
Improve tests of governable contract (#503)
axelizsak Oct 8, 2023
bbae062
add new contributors (#505)
axelizsak Oct 9, 2023
e179caf
Moving test_strict_bank to tests/bank directory (#506)
VictorONN Oct 10, 2023
d8a4928
test: Improve tests of base_order_utils (#507)
tevrat-aksoy Oct 11, 2023
2a1fcd9
Feat: Implemented exchange_router contract (#504)
sparqet Oct 12, 2023
3ee6d81
Deployment: Improved Deployement Scripts (#513)
sparqet Oct 12, 2023
d0be8d5
Fix: typos (#514)
omahs Oct 12, 2023
88d2204
Fix: Tmp fix cause we cannot use move in the struct so I returned a c…
Sk8erboi84 Oct 12, 2023
a8ecb2d
Feat/decrease order utils (#517)
Sk8erboi84 Oct 13, 2023
640e7d2
dev: Add devcontainer (#520)
khaeljy Oct 13, 2023
5b114cd
Feat/swap order utils (#519)
Sk8erboi84 Oct 13, 2023
38ee6a6
Remove tests folder from src (#522)
sparqet Oct 14, 2023
309dc1a
Global reentrency swap_handler (#523)
sparqet Oct 14, 2023
e4610c6
tests: Fix event tests for snforge 0.8+ (#524)
akhercha Oct 14, 2023
532fe5f
feat: fix test for snforge 0.8.0 (#521)
zarboq Oct 15, 2023
01249b6
Feat: increase_position_utils library (#510)
sparqet Oct 15, 2023
a798a16
Added missing functions deposit_vault (#528)
sparqet Oct 15, 2023
3b1e2e8
dev: Update starknet-foundry to 0.8.2 in devcontainer.json (#527)
khaeljy Oct 15, 2023
9799873
Fix contructor args order (#530)
khaeljy Oct 15, 2023
82c7043
Fix Satoru book oracle module description (#531)
satyambnsal Oct 15, 2023
63a6204
test: Improve tests of base_order_handler contract (#529)
akhercha Oct 16, 2023
b52f429
Added new contributor to the project (#534)
Sk8erboi84 Oct 16, 2023
2117ffd
feat: use snforge v0.8.3 (#535)
zarboq Oct 17, 2023
05ad1b5
fix: `u32_sub Overflow` if the index isn't found in datastore (#536)
khaeljy Oct 17, 2023
7784ecb
feat: `withdrawal_vault` implementation (#526)
khaeljy Oct 18, 2023
3a1dfdd
Reimplement all i128 library & fix all functions and tests related to…
sparqet Oct 18, 2023
30ad52e
fix_tests: swap_pricing_utils (#541)
sparqet Oct 18, 2023
4208819
implemented i128 tests (#542)
sparqet Oct 19, 2023
6ce3682
test: add a test for `exchange_utils` (#383)
delaaxe Oct 19, 2023
8789bac
feat: modify data_store behavior when getting structs (#533)
khaeljy Oct 20, 2023
0f09471
fix and add missing market_utils functions (#545)
sparqet Oct 20, 2023
abd452c
fix: order/position utils files (#548)
sparqet Oct 21, 2023
4f0115d
Implemented order_utils functions (#546)
sparqet Oct 21, 2023
d14c7ea
feat/create_order_utils (#550)
sparqet Oct 22, 2023
cee8cb8
fix error in book (#551)
waopoed Oct 22, 2023
577be75
fix to_signed() with correct sign (#553)
sparqet Oct 22, 2023
60e341e
fix: execute_deposit_utils (#554)
sparqet Oct 23, 2023
4d94615
fix: set semgrep version in CI to 1.45.0 (#559)
zarboq Oct 26, 2023
df72ee4
fix: typo readme (#557)
zarboq Oct 26, 2023
3f22d46
Added deployed contracts for Swap (#560)
sparqet Oct 26, 2023
9f3d431
fix/Negative sign function (#562)
sparqet Oct 26, 2023
21c7e18
Improve test widthdrawal handler (#549)
0xTitan Oct 26, 2023
d57ac9c
Feat : CI Starknet Foundry (#564)
Sk8erboi84 Oct 26, 2023
e3396ce
already defined variable (#563)
JeanWoked Oct 26, 2023
0279862
fix option return value in data_store.cairo (#565)
sparqet Oct 26, 2023
52d60a5
fix: correct the variable name (#566)
vuittont60 Oct 27, 2023
d208831
Improve tests of position_utils library. (#547)
ArnaudBger Oct 27, 2023
dd0ca39
👥 Add contributors (#569)
zarboq Oct 27, 2023
4047c6d
Feat: Added the Satoru compatible frontends (#571)
Sk8erboi84 Oct 31, 2023
282539e
feat: Use indexes for LogData (#539)
akhercha Nov 1, 2023
c1253da
feat: Remove all inlines (#574)
sparqet Nov 2, 2023
9b1c439
tests: Added tests for SerializableFelt252Dict (#573)
akhercha Nov 2, 2023
08409a1
feat: update scarb and snforge versions (#575)
zarboq Nov 2, 2023
12aca79
feat: implement oracle_utils (#570)
zarboq Nov 2, 2023
7652e76
Update .tool-versions (#577)
enitrat Nov 3, 2023
3012364
Tests: Adl_Utils resolving conflicts (#578)
faytey Nov 3, 2023
0a109aa
:busts_in_silhouette: Add @faytey as a contributor (#579)
zarboq Nov 3, 2023
0c9ad1a
bump: Update cairo syntax (#580)
akhercha Nov 5, 2023
5cfb1ed
Feat: implement-apply_exponent_factor-function-in-precision (#456)
StarkFishinator Nov 5, 2023
01e3bf3
fix:bad typo (#581)
BibFlu Nov 7, 2023
aba8e40
Feat/snforge0.9.1 (#582)
zarboq Nov 7, 2023
bf0aa34
feat: implement `oracle_store` (#584)
zarboq Nov 9, 2023
44ac3b0
Integration Test: Add Liquidity with unauthorized address (#585)
sparqet Nov 9, 2023
01a0624
Update snforge (#587)
Sk8erboi84 Nov 11, 2023
d2b20d0
feat: add test_will_position_collateral_be_sufficient (#588)
FelixGibson Nov 12, 2023
f923d34
fix: fix TODOs (#590)
sparqet Nov 18, 2023
3c7c3cd
fix: fix execute_deposit_utils (#592)
sparqet Nov 18, 2023
665dd8c
Fix: TODO for error message (#593)
Sk8erboi84 Nov 19, 2023
29efe35
feat: integration test for swap (#586)
zarboq Nov 20, 2023
8c0b778
feat: Integration test for adding liquidity (#594)
sparqet Nov 20, 2023
59b2735
Improve tests of liquidation_handler contract (#589)
tevrat-aksoy Nov 23, 2023
7207058
Use SCARB_VERSION in CI (#596)
piotmag769 Nov 24, 2023
4bc77b7
Fix/integration test deposit liquidity (#597)
sparqet Nov 24, 2023
c027d2b
Update token_utils.cairo (#598)
Kevin00Hendrik Nov 27, 2023
de35002
Feat/infrastructure (#599)
sparqet Nov 28, 2023
e665cfe
Added 14 unit tests to `test_reader.cairo` (#561)
Akinbola247 Jan 3, 2024
d032c38
Added 3 unit tests, Refactored 1 test in test_swap_handler.cairo (#603)
Akinbola247 Jan 21, 2024
567512a
dev: added exploration badge (#605)
drspacemn Jan 23, 2024
571dc67
Add increment of cur_idx in with_simulated_oracle_prices_before funct…
0xandee Jan 26, 2024
3b35d1a
Fix bug List index out of bounds when remove last index element in Da…
0xandee Jan 26, 2024
0e8cda3
Update Semgrep Rules and Semgrep config path for CI (#609)
0xandee Jan 29, 2024
92a4571
feat: full deployment script in ts (#613)
zarboq Feb 13, 2024
ef79e35
Migrating u128 to u256 (#615)
prtk418 Mar 7, 2024
6ebc1a4
Calc logic and unit test fixes (#617)
prtk418 Mar 8, 2024
6f896f4
test/Merge all working test with u256 (#629)
sparqet Mar 20, 2024
9267123
fixed integration tests with u256 (#630)
sparqet Mar 20, 2024
e80b5de
test/fixed deposit test (#631)
sparqet Mar 21, 2024
cd3d6c9
Test/ added withdrawal creation (#632)
sparqet Mar 23, 2024
6b3ebe6
Test/ Deposit and withdrawal passing integration test (#633)
sparqet Mar 23, 2024
9d85b40
Test/fix cairo format (#634)
sparqet Mar 23, 2024
63b22e2
refactor integration tests (#636)
sparqet Mar 28, 2024
18dd623
Fix/swap - Swap test working fine (#637)
Sk8erboi84 Mar 30, 2024
1021dee
Added the pool amount for long (#638)
Sk8erboi84 Apr 1, 2024
d0ac1ae
Test/short integration passing (#639)
sparqet Apr 2, 2024
50744a2
Test/close long position (#635)
sparqet Apr 4, 2024
4cebcc9
Fix/fix short market swap (#640)
sparqet Apr 4, 2024
b5416be
Fix/order handler shorter (#641)
sparqet Apr 21, 2024
f54610c
Feat: decrease order handler size (#642)
zarboq Apr 25, 2024
42ddca8
Fix/fix oracle size (#643)
sparqet Apr 27, 2024
146d02c
Test/ long and swap 18 decimal (#645)
sparqet May 1, 2024
ee3a03d
Fix/updated position size decrease (#646)
sparqet May 4, 2024
068550d
Fix/fix oracle size (#644)
sparqet May 4, 2024
10e15ea
Refactor/clean const contract address (#647)
sparqet May 4, 2024
83861b4
fix/fix_setter_pnl_factor_tests (#648)
sparqet May 5, 2024
534e3c8
Test/all test demo (#650)
sparqet May 8, 2024
b9b542f
Feat: decrease order_handler size & add script to simulate user actio…
zarboq May 13, 2024
2953631
fix: modify withdrawal event fields & uncomment tests (#654)
zarboq May 13, 2024
742ae99
Revert "fix: modify withdrawal event fields & uncomment tests" (#655)
sparqet May 14, 2024
c092116
feat: modify withdrawal event struct (#656)
zarboq May 14, 2024
3961a32
feat: use library calls (#658)
zarboq May 15, 2024
67d545f
Test/close short test (#659)
sparqet May 15, 2024
35a1adf
Feat/liquidation checker (#663)
sparqet Jun 15, 2024
0be6ab7
Feat/take profit trigger Long (#661)
sparqet Jun 17, 2024
741ae8f
Feat/tested execute liquidation (#664)
sparqet Jun 18, 2024
b0ec18b
feat: deploy exchange router (#665)
zarboq Jun 18, 2024
3012f4d
Feat/liquidation fails (#666)
sparqet Jun 18, 2024
3f3a1c0
Fix/remove commented codelines (#662)
sparqet Jun 18, 2024
56d39cd
Feat/add pragma lib (#667)
sparqet Jun 18, 2024
892c19b
feat: update deployment script (#668)
zarboq Jun 18, 2024
ba7b240
Feat/implement all oracle functions and link to pragma (#669)
sparqet Jun 19, 2024
2bf7371
feat: add controller role to exchangeRouter (#670)
zarboq Jun 19, 2024
168c876
Feat/oracle adapted for tests (#671)
sparqet Jun 19, 2024
c250cb7
Test/open long and increase (#672)
sparqet Jun 20, 2024
7e8d5c8
Test: Open/Increase/Decrease/Close Long position (#673)
sparqet Jun 21, 2024
67edd38
Test/oracle set price params (#674)
sparqet Jun 21, 2024
7e70a2e
Fix: deposit pool value error (#675)
zarboq Jun 24, 2024
000ded5
fix: fix key field in Order and Withdrawal (#676)
zarboq Jun 24, 2024
78096cd
Test/use exchange router (#677)
sparqet Jun 24, 2024
d1a30f3
Test/ Trigger Increase & Decrease Long (#678)
sparqet Jun 24, 2024
b749886
Test/trigger fails test Increase Decrease Close (#679)
sparqet Jun 25, 2024
274495d
Test/swap test pass (#680)
sparqet Jun 25, 2024
2e105a1
Test/use send tokens function (#681)
sparqet Jun 26, 2024
24c0b1f
Test/refactor deploy setup (#682)
sparqet Jun 26, 2024
09e40db
Test/short open close (#683)
sparqet Jun 27, 2024
f3a5732
Fix/fix double pay order (#684)
sparqet Jun 27, 2024
afb2213
Test/fix message assert (#685)
sparqet Jun 27, 2024
e5f6f4b
Test/liquidation test (#686)
sparqet Jun 29, 2024
aa9dba9
Test/leveraged position & liquidable leveraged position (#687)
sparqet Jun 29, 2024
75b73a1
deployment/set missing u256 constants for testnet (#688)
sparqet Jun 30, 2024
9ea6b2d
Feat/is liquidable func (#689)
sparqet Jul 3, 2024
a2fb657
Refactor/deposit function (#690)
sparqet Jul 3, 2024
6b6514c
Refactor/execution (#691)
sparqet Jul 26, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
117 changes: 117 additions & 0 deletions .all-contributorsrc
Original file line number Diff line number Diff line change
Expand Up @@ -234,6 +234,123 @@
"contributions": [
"code"
]
},
{
"login": "piotmag769",
"name": "Piotr Magiera",
"avatar_url": "https://avatars.githubusercontent.com/u/56825108?v=4",
"profile": "https://github.com/piotmag769",
"contributions": [
"code"
]
},
{
"login": "ftupas",
"name": "ftupas",
"avatar_url": "https://avatars.githubusercontent.com/u/35031356?v=4",
"profile": "https://github.com/ftupas",
"contributions": [
"code"
]
},
{
"login": "lambda-0x",
"name": "lambda-0x",
"avatar_url": "https://avatars.githubusercontent.com/u/87354252?v=4",
"profile": "https://github.com/lambda-0x",
"contributions": [
"code"
]
},
{
"login": "Tbelleng",
"name": "Tbelleng",
"avatar_url": "https://avatars.githubusercontent.com/u/117627242?v=4",
"profile": "https://github.com/Tbelleng",
"contributions": [
"code"
]
},
{
"login": "dic0de",
"name": "dic0de",
"avatar_url": "https://avatars.githubusercontent.com/u/37063500?v=4",
"profile": "https://github.com/dic0de",
"contributions": [
"code"
]
},
{
"login": "akhercha",
"name": "akhercha",
"avatar_url": "https://avatars.githubusercontent.com/u/22559023?v=4",
"profile": "https://github.com/akhercha",
"contributions": [
"code"
]
},
{
"login": "VictorONN",
"name": "VictorONN",
"avatar_url": "https://avatars.githubusercontent.com/u/73134512?v=4",
"profile": "https://github.com/VictorONN",
"contributions": [
"code"
]
},
{
"login": "kasteph",
"name": "kasteph",
"avatar_url": "https://avatars.githubusercontent.com/u/3408478?v=4",
"profile": "https://github.com/kasteph",
"contributions": [
"code"
]
},
{
"login": "khaeljy",
"name": "Khaeljy",
"avatar_url": "https://avatars.githubusercontent.com/u/1810456?v=4",
"profile": "https://github.com/khaeljy",
"contributions": [
"code"
]
},
{
"login": "JeanWoked",
"name": "JeanWoked",
"avatar_url": "https://avatars.githubusercontent.com/u/149107619?v=4",
"profile": "https://github.com/JeanWoked",
"contributions": [
"code"
]
},
{
"login": "vuittont60",
"name": "vuittont60",
"avatar_url": "https://avatars.githubusercontent.com/u/81072379?v=4",
"profile": "https://github.com/vuittont60",
"contributions": [
"code"
]
},
{
"login": "MavericksFive",
"name": "Arnaud Berger",
"avatar_url": "https://avatars.githubusercontent.com/u/95299145?v=4",
"profile": "https://github.com/MavericksFive",
"contributions": [
"code"
]
},
{
"login": "faytey",
"name": "faytey",
"avatar_url": "https://avatars.githubusercontent.com/u/40033608?v=4",
"profile": "https://github.com/faytey",
"contributions": [
"code"
]
}
],
"contributorsPerLine": 7,
Expand Down
10 changes: 10 additions & 0 deletions .devcontainer/devcontainer.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
{
"name": "Satoru",
"image": "mcr.microsoft.com/devcontainers/base:jammy",
"customizations": {
"vscode": {
"extensions": ["starkware.cairo1"]
}
},
"postCreateCommand": "curl --proto '=https' --tlsv1.2 -sSf https://docs.swmansion.com/scarb/install.sh | sh && curl -L https://raw.githubusercontent.com/foundry-rs/starknet-foundry/master/scripts/install.sh | sh -s -- -v 0.8.3"
}
3 changes: 3 additions & 0 deletions .example.env
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
PROVIDER_URL=
ACCOUNT_PUBLIC=
ACCOUNT_PRIVATE=
46 changes: 46 additions & 0 deletions .github/semgrep-cairo-rules.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,46 @@
rules:
- id: unwrap
message: Use unwrap() method on $X, use expect() instead
languages: [cairo]
severity: WARNING
pattern: $X.unwrap()

- id: division
message: Possible division by zero, use error_utils::check_division_by_zero to report a better error message
languages: [cairo]
severity: WARNING
patterns:
- pattern-regex: $Y / $X
- pattern-not-regex: error_utils::check_division_by_zero

- id: reentrancy
message: |
Value mutated after call to external contract
severity: ERROR
mode: join
join:
rules:
- id: external-contract-declaration
languages: [cairo]
pattern: |
trait $SOME_CONTRACT {}
- id: external-call
languages: [cairo]
pattern: |
$SOME_CONTRACT::transfer(...);
...;
$X::write(...);
on:
- 'external-contract-declaration.$SOME_CONTRACT == external-call.$SOME_CONTRACT'

- id: unsafe-arithmetic
message: Call unsafe math operators on $X
languages: [cairo]
severity: ERROR
pattern-either:
- pattern: $X + $Y
- pattern: $X += ...
- pattern: $X - $Y
- pattern: $X -= ...
- pattern: $X * $Y
- pattern: $X *= ...
4 changes: 2 additions & 2 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ name: Build
on: [push, pull_request]

env:
SCARB_VERSION: 0.7.0
SCARB_VERSION: 2.3.1

# For the moment we will use nightly versions of scarb to be able to use latest features of Cairo.
# The installation process will be a bit different than when using non nightly versions.
Expand All @@ -15,7 +15,7 @@ jobs:
- uses: actions/checkout@v3
- uses: software-mansion/setup-scarb@v1
with:
scarb-version: "0.7.0"
scarb-version: "2.3.1"
# - name: Set up Scarb
#ses: software-mansion/setup-scarb@v1
# Install Scarb from a nightly release
Expand Down
38 changes: 19 additions & 19 deletions .github/workflows/security.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,13 +9,13 @@ jobs:
- uses: actions/checkout@v3
- uses: software-mansion/setup-scarb@v1
with:
scarb-version: "0.7.0"
scarb-version: "2.3.1"

- name: Install Semgrep
run: |
pip install semgrep
pip install semgrep==1.45.0
- name: Run Semgrep
run: semgrep --config https://github.com/avnu-labs/semgrep-cairo-rules/releases/download/v0.0.1/cairo-rules.yaml ./src > semgrep-output.txt
run: semgrep --config .github/semgrep-cairo-rules.yaml ./src > semgrep-output.txt
- name: Save Semgrep Output as an Artifact
uses: actions/upload-artifact@v3
with:
Expand All @@ -32,19 +32,19 @@ jobs:
~/.cargo
key: ${{ runner.os }}-cargo-${{ hashFiles('**/Cargo.lock') }}

- name: Check if Caracal is installed
id: check-caracal
run: |
if ! command -v caracal &> /dev/null; then
echo "Caracal is not installed. Installing..."
cargo install --git https://github.com/crytic/caracal --profile release --force
else
echo "Caracal is already installed."
fi
- name: Run Caracal
run: caracal detect . > caracal-output.txt
- name: Save Caracal Output as an Artifact
uses: actions/upload-artifact@v3
with:
name: caracal-cairo
path: caracal-output.txt
# - name: Check if Caracal is installed
# id: check-caracal
# run: |
# if ! command -v caracal &> /dev/null; then
# echo "Caracal is not installed. Installing..."
# cargo install --git https://github.com/crytic/caracal --profile release --force
# else
# echo "Caracal is already installed."
# fi
# - name: Run Caracal
# run: caracal detect . > caracal-output.txt
# - name: Save Caracal Output as an Artifact
# uses: actions/upload-artifact@v3
# with:
# name: caracal-cairo
# path: caracal-output.txt
14 changes: 7 additions & 7 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,7 @@ name: Test
on: [push, pull_request]

env:
SCARB_VERSION: 0.7.0
STARKNET_FOUNDRY_VERSION: 0.6.0
SCARB_VERSION: 2.3.1

jobs:
check:
Expand All @@ -13,7 +12,12 @@ jobs:
- uses: actions/checkout@v3
- uses: software-mansion/setup-scarb@v1
with:
scarb-version: "0.7.0"
scarb-version: ${{ env.SCARB_VERSION }}
- uses: foundry-rs/setup-snfoundry@v2
with:
starknet-foundry-version: 0.10.1
- name: Run cairo tests
run: snforge test
# - name: Set up Scarb
#ses: software-mansion/setup-scarb@v1
# Install Scarb from a nightly release
Expand All @@ -22,7 +26,3 @@ jobs:
# wget https://github.com/software-mansion/scarb-nightlies/releases/download/${NIGHTLY_DATE}/scarb-${NIGHTLY_DATE}-x86_64-unknown-linux-gnu.tar.gz
# tar -xvf scarb-${NIGHTLY_DATE}-x86_64-unknown-linux-gnu.tar.gz
# sudo mv scarb-v${SCARB_VERSION}-x86_64-unknown-linux-gnu/bin/scarb /usr/local/bin
- name: Install starknet foundry
run: curl -L https://raw.githubusercontent.com/foundry-rs/starknet-foundry/master/scripts/install.sh | sh -s -- -v ${STARKNET_FOUNDRY_VERSION}
- name: Run cairo tests
run: snforge
4 changes: 3 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -13,4 +13,6 @@ Cargo.lock
# MSVC Windows builds of rustc generate these, which store debugging information
*.pdb

**/.DS_Store
**/.DS_Store
.env
node_modules
2 changes: 1 addition & 1 deletion .tool-versions
Original file line number Diff line number Diff line change
@@ -1 +1 @@
scarb 0.7.0
scarb 2.3.1
Loading