-
Notifications
You must be signed in to change notification settings - Fork 108
[contract] Add 3 Tests to escrow_tests.rs (Part 1)Β #524
Copy link
Copy link
Open
Labels
ContractStellar WaveIssues in the Stellar wave programIssues in the Stellar wave programescrowtest-expansiontesting
Description
π Overview
Expand test coverage for the escrow module by adding 3 new tests (Part 1 of 2).
β Tasks
- Add 3 new test functions to
contract/tests/escrow_tests.rs - Follow existing test patterns and helper functions
- Verify all tests pass
π§ͺ New Tests (3 total)
Test 1: Lock Stake Multiple Users
#[test]
fn test_lock_stake_multiple_users() {
// Lock stakes for multiple users
// Verify each user's balance is tracked separately
// Verify total locked amount is correct
}Test 2: Release Payout Partial Amount
#[test]
fn test_release_payout_partial_amount() {
// Lock stake
// Release partial payout
// Verify remaining locked balance
// Release rest
// Verify balance is zero
}Test 3: Lock Stake Insufficient Balance
#[test]
fn test_lock_stake_insufficient_balance() {
// Try to lock more than user has
// Should fail with insufficient balance error
}π Verification
- All 3 tests written
- All tests pass
- Tests follow existing patterns
- No clippy warnings
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
ContractStellar WaveIssues in the Stellar wave programIssues in the Stellar wave programescrowtest-expansiontesting