@@ -1328,8 +1328,8 @@ describe('WarmStorageService', () => {
13281328 assert . exists ( check . depositAmountNeeded )
13291329 assert . isTrue ( check . depositAmountNeeded > 0n )
13301330
1331- // depositAmountNeeded should equal 10 days of costs (default lockup)
1332- const expectedDeposit = check . costs . perEpoch * BigInt ( 10 ) * BigInt ( TIME_CONSTANTS . EPOCHS_PER_DAY )
1331+ // depositAmountNeeded should equal 30 days of costs (default lockup)
1332+ const expectedDeposit = check . costs . perEpoch * TIME_CONSTANTS . DEFAULT_LOCKUP_DAYS * TIME_CONSTANTS . EPOCHS_PER_DAY
13331333 assert . equal ( check . depositAmountNeeded . toString ( ) , expectedDeposit . toString ( ) )
13341334 } )
13351335
@@ -1373,27 +1373,27 @@ describe('WarmStorageService', () => {
13731373 return `0x${ '0' . repeat ( 64 ) } `
13741374 }
13751375
1376- // Test with custom lockup period of 20 days
1377- const customLockupDays = 20
1376+ // Test with custom lockup period of 60 days
1377+ const customLockupDays = TIME_CONSTANTS . DEFAULT_LOCKUP_DAYS * 2n
13781378 const check = await warmStorageService . checkAllowanceForStorage (
13791379 Number ( SIZE_CONSTANTS . GiB ) , // 1 GiB
13801380 false ,
13811381 mockPaymentsService ,
1382- customLockupDays
1382+ Number ( customLockupDays )
13831383 )
13841384
13851385 // Verify depositAmountNeeded uses custom lockup period
1386- const expectedDeposit = check . costs . perEpoch * BigInt ( customLockupDays ) * BigInt ( TIME_CONSTANTS . EPOCHS_PER_DAY )
1386+ const expectedDeposit = check . costs . perEpoch * customLockupDays * TIME_CONSTANTS . EPOCHS_PER_DAY
13871387 assert . equal ( check . depositAmountNeeded . toString ( ) , expectedDeposit . toString ( ) )
13881388
1389- // Compare with default (10 days) to ensure they're different
1389+ // Compare with default (30 days) to ensure they're different
13901390 const defaultCheck = await warmStorageService . checkAllowanceForStorage (
13911391 Number ( SIZE_CONSTANTS . GiB ) , // 1 GiB
13921392 false ,
13931393 mockPaymentsService
13941394 )
13951395
1396- // Custom should be exactly 2x default (20 days vs 10 days)
1396+ // Custom should be exactly 2x default (60 days vs 30 days)
13971397 assert . equal ( check . depositAmountNeeded . toString ( ) , ( defaultCheck . depositAmountNeeded * 2n ) . toString ( ) )
13981398 } )
13991399 } )
0 commit comments