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

Feature/swaps via call #29

Open
wants to merge 54 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from 16 commits
Commits
Show all changes
54 commits
Select commit Hold shift + click to select a range
34072f9
del DexType enum and add dexRouter
AleksiGer Nov 18, 2024
c5d248c
natspec
AleksiGer Nov 18, 2024
9cbdc29
add InsufficientAmount error
AleksiGer Nov 18, 2024
9b3f94f
add additional after swap check
AleksiGer Nov 18, 2024
6e9d021
implement _performSwap fn
AleksiGer Nov 18, 2024
e924f8d
delete unused param
AleksiGer Nov 18, 2024
1a3b71f
add receiving tokens by the user
AleksiGer Nov 18, 2024
f85c295
delete unused
AleksiGer Nov 18, 2024
d38fd96
add new tokens
AleksiGer Nov 21, 2024
3ecfbd7
add args in forks
AleksiGer Nov 21, 2024
b6f43f2
add tests for DexSwap
AleksiGer Nov 21, 2024
f654b9a
delete useless checks and calls
AleksiGer Nov 21, 2024
aa5cbe6
add new tokens
AleksiGer Nov 22, 2024
5d42039
add avalanche fork
AleksiGer Nov 22, 2024
f25392e
add polygon & avalanche tests
AleksiGer Nov 22, 2024
eb1b154
add forks and funcs for them
AleksiGer Nov 22, 2024
47ab350
optimize comparison
AleksiGer Nov 29, 2024
980bc7e
optimize conditions
AleksiGer Nov 29, 2024
0f85554
delete comments and unused imports
AleksiGer Nov 29, 2024
dd5b309
delete abicoder v2 because it already presents since 0.8.0
AleksiGer Nov 29, 2024
b150278
Merge branch 'master' into feature/swaps-via-call
lufaque Dec 15, 2024
2757f1a
fix naming issues
lufaque Dec 15, 2024
543ec88
new test suit base
lufaque Dec 16, 2024
11d1b13
uni v3 test
lufaque Dec 16, 2024
36249f5
add view
AleksiGer Dec 16, 2024
3c2077e
update naming
lufaque Dec 17, 2024
4538e9f
update dex swap, add univ3 and sushi swap tests
lufaque Dec 17, 2024
07eeb59
fix typo
AleksiGer Dec 17, 2024
69e58cc
update dex swap, add univ3 and sushi swap tests
lufaque Dec 17, 2024
ea28efc
Merge remote-tracking branch 'origin/feature/swaps-via-call' into fea…
lufaque Dec 17, 2024
23870e5
sushi swap, uniswap tests
lufaque Dec 17, 2024
0eeda0f
uni, quickswap and alienbase tests
AleksiGer Dec 17, 2024
489a2ef
add polygon, avalanche, optimism
AleksiGer Dec 17, 2024
4039e8d
Merge branch 'feature/swaps-via-call' of https://github.com/concero/c…
AleksiGer Dec 17, 2024
84e84ba
reorder tests and fix name
AleksiGer Dec 17, 2024
5dff768
remove comments
lufaque Dec 18, 2024
a41d35f
fix env names
lufaque Dec 18, 2024
01737df
remove unused imports
lufaque Dec 18, 2024
7298656
reformat label
AleksiGer Dec 18, 2024
5f31617
Merge branch 'feature/swaps-via-call' of https://github.com/concero/c…
AleksiGer Dec 18, 2024
6767f77
setup solhint
lufaque Dec 20, 2024
3a654d4
Merge remote-tracking branch 'origin/feature/swaps-via-call' into fea…
lufaque Dec 20, 2024
6f6634e
update set contracts task
lufaque Dec 23, 2024
e194fe9
rename dexData to dexCallData
AleksiGer Dec 23, 2024
178e2bc
Merge branch 'feature/swaps-via-call' of https://github.com/concero/c…
AleksiGer Dec 23, 2024
83ce309
rename dexData to dexCallData
AleksiGer Dec 23, 2024
338da27
add tokens
AleksiGer Dec 25, 2024
f929cfb
add wrapped to whitelist
AleksiGer Dec 25, 2024
bf18749
add new tests for native and wrapped
AleksiGer Dec 25, 2024
7fc08cb
update deploy dex swap script
lufaque Dec 25, 2024
14a17d8
add pangolin
AleksiGer Dec 26, 2024
598bc34
add tests for pangolin avalanche
AleksiGer Dec 26, 2024
69f323d
rename
AleksiGer Dec 26, 2024
388c972
Merge branch 'feature/swaps-via-call' of https://github.com/concero/c…
AleksiGer Dec 26, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
20 changes: 20 additions & 0 deletions .env.tokens
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,26 @@ USDC_POLYGON=0x3c499c542cEF5E3811e1192ce70d8cC03d5c3359
USDC_AVALANCHE=0xB97EF9Ef8734C71904D8002F8b6Bc66Dd9c48a6E
USDC_BASE=0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913

# USDT MAINNET
USDT_ARBITRUM=0xfd086bc7cd5c481dcc9c85ebe478a1c0b69fcbb9

# WETH MAINNET
WETH_BASE=0x4200000000000000000000000000000000000006
WETH_ARBITRUM=0x82aF49447D8a07e3bd95BD0d56f35241523fBab1
WETH_POLYGON=0x7ceb23fd6bc0add59e62ac25578270cff1b9f619

# WAVAX MAINNET
WAVAX_AVALANCHE=0xB31f66AA3C1e785363F0875A1B74E27b85FD66c7

# DAI MAINNET
DAI_BASE=0x50c5725949A6F0c72E6C4a641F24049A917DB0Cb

# SUSHI MAINNET
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

is this sushi dex or sushi token?

SUSHI_BASE=0x7d49a065d17d6d4a55dc13649901fdbb98b2afba

# 1INCH TOKEN MAINNET
1INCH_BASE=0xc5fecC3a29Fb57B5024eEc8a2239d4621e111CBE

# USDC TESTNET
USDC_SEPOLIA=0x1c7D4B196Cb0C7B01d743Fbc6116a902379C7238
USDC_ARBITRUM_SEPOLIA=0x75faf114eafb1BDbe2F0316DF893fd58CE46AA4d
Expand Down
10 changes: 8 additions & 2 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -30,10 +30,16 @@ install:
grep -E '^\s*url' ./.gitmodules | awk '{print $$3}' | xargs -I {} sh -c 'forge install {}'

run_fork:
anvil --fork-url ${BASE_RPC_URL} -p ${BASE_LOCAL_FORK_PORT}
anvil --fork-url ${BASE_RPC_URL} -p ${BASE_LOCAL_FORK_PORT} $(args)

run_arb_fork:
anvil --fork-url ${ARB_RPC_URL} -p ${ARB_LOCAL_FORK_PORT}
anvil --fork-url ${ARB_RPC_URL} -p ${ARB_LOCAL_FORK_PORT} $(args)

run_polygon_fork:
anvil --fork-url ${POLYGON_RPC_URL} -p ${POLYGON_LOCAL_FORK_PORT} $(args)

run_avalanche_fork:
anvil --fork-url ${AVALANCHE_RPC_URL} -p ${AVALANCHE_LOCAL_FORK_PORT} $(args)

test:
forge test $(args)
Expand Down
Loading