Skip to content

Feat/bridge adapters - #1

Merged
kraikov merged 6 commits into
mainfrom
feat/bridge-adapters
Jul 9, 2026
Merged

Feat/bridge adapters#1
kraikov merged 6 commits into
mainfrom
feat/bridge-adapters

Conversation

@kraikov

@kraikov kraikov commented Jul 9, 2026

Copy link
Copy Markdown
Contributor

No description provided.

kraikov added 6 commits July 7, 2026 22:15
- Implemented `CcipForkTest` for YoCcipAdapter to test CCIP transfers with USDC and LINK.
- Added `CctpForkTest` for YoCctpAdapter to validate CCTP deposit and burn functionality.
- Created `MayanForkTest` for YoMayanAdapter to ensure proper forwarding of USDC through Mayan protocols.
- Developed fuzz tests for AcrossAdapter deposit functionality to ensure robust handling of various inputs.
- Added fuzz tests for BridgeRouteRegistry to validate route setting and isolation.
- Implemented fuzz tests for CCIP adapter send functionality to cover various fee scenarios.
- Created fuzz tests for CCTP adapter depositForBurn to ensure correct behavior under different conditions.
- Added fuzz tests for Mayan adapter to validate ERC20 forwarding and route restrictions.
- Introduced mock contracts for AcrossSpokePool, CCIP Router, Mayan Forwarder, TokenMessengerV2 to facilitate testing.
- Updated Defaults contract with constants for bridge amounts, destination IDs, and fee structures.
…rer restrictions

- Updated order validation to ensure no referrer is allowed and custom payloads are prohibited.
- Added error handling for referrer and custom payload violations in IYoMayanAdapter.
- Modified _decodeOrder function to enforce empty custom payload requirement.
- Enhanced comments and documentation for clarity on order processing rules.

feat: Introduce renounceOwnership restriction in YoBridgeRouteRegistry

- Implemented a revert mechanism for renounceOwnership to prevent freezing of routes.

feat: Add CCIP adapter error handling for non-EVM recipients and native value with token fee

- Introduced new errors in IYoCcipAdapter for invalid recipient addresses and unexpected native value.

test: Add integration tests for CCIP native fee handling and Mayan adapter order validation

- Created tests for native fee handling in CCIP adapter via YoVault.manage.
- Added fuzz tests for Mayan adapter to validate referrer and custom payload restrictions.
- Implemented end-to-end tests for Aave V4 Tokenization Spoke integration.

fix: Update MockAcrossSpokePool to capture last calldata for verification

- Added lastCalldata storage in MockAcrossSpokePool to facilitate testing of calldata integrity.
- Updated IYoBridgeRouteRegistry to include outputToken as a key field for routes.
- Modified YoBridgeRouteRegistry to handle outputToken in setRoute and isRouteAllowed functions.
- Adjusted tests to accommodate changes in route handling, including fuzz tests for route validation.
- Enhanced integration tests for Across, CCTP, and Mayan adapters to utilize outputToken.
- Added checks for slippage and swap pair validation in Mayan adapter tests.
- Updated comments and documentation to reflect the new outputToken functionality.
…er handling

- Added test case for reverting with MinAmountOutTooLow in SwapAndForwardERC20.
- Updated CcipForkTest to remove LINK references and adjust fee handling.
- Refactored CctpForkTest to include MAX_FEE_BPS and simplify depositForBurn calls.
- Improved MayanForkTest by integrating MayanOrders for order creation and validation.
- Enhanced fuzz tests for CCIP and CCTP adapters to cover fee scenarios and revert conditions.
- Introduced MayanOrders utility for consistent order parameter creation across tests.
- Updated Defaults to include new constants for max slippage and fee caps.
@kraikov
kraikov merged commit 16149b5 into main Jul 9, 2026
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant