@@ -35,7 +35,7 @@ use orml_traits::MultiCurrency;
3535use xcm:: latest:: { Junction , Junction :: * , Junctions :: * , MultiLocation , NetworkId } ;
3636use xcm_emulator:: { Limited , TestExt } ;
3737use zeitgeist_primitives:: {
38- constants:: BalanceFractionalDecimals ,
38+ constants:: { BalanceFractionalDecimals , BASE } ,
3939 types:: { CustomMetadata , XcmMetadata } ,
4040} ;
4141
@@ -87,9 +87,6 @@ fn transfer_ztg_to_sibling() {
8787 // Verify that BOB now has (amount transferred - fee)
8888 assert_eq ! ( current_balance, transfer_amount - ztg_fee( ) ) ;
8989
90- // Sanity check for the actual amount BOB ends up with
91- assert_eq ! ( current_balance, 49_907_304_000 ) ;
92-
9390 // Verify that fees (of foreign currency) have been put into treasury
9491 assert_eq ! (
9592 Tokens :: free_balance( FOREIGN_ZTG_ID , & ZeitgeistTreasuryAccount :: get( ) ) ,
@@ -352,7 +349,7 @@ fn transfer_roc_to_relay_chain() {
352349 } ) ;
353350
354351 RococoNet :: execute_with ( || {
355- assert_eq ! ( rococo_runtime:: Balances :: free_balance( & BOB ) , 999_988_806_429 ) ;
352+ assert_eq ! ( rococo_runtime:: Balances :: free_balance( & BOB ) , 999_988_690_728 ) ;
356353 } ) ;
357354}
358355
@@ -419,10 +416,7 @@ fn transfer_ztg_to_sibling_with_custom_fee() {
419416 let custom_fee = calc_fee ( default_per_second ( 10 ) * 10 ) ;
420417
421418 // Verify that BOB now has (amount transferred - fee)
422- assert_eq ! ( current_balance, transfer_amount - custom_fee) ;
423-
424- // Sanity check for the actual amount BOB ends up with
425- assert_eq ! ( current_balance, 49_073_040_000 ) ;
419+ assert_eq ! ( current_balance, transfer_amount - ztg_fee( ) * fee_factor / BASE ) ;
426420
427421 // Verify that fees (of foreign currency) have been put into treasury
428422 assert_eq ! (
@@ -434,8 +428,8 @@ fn transfer_ztg_to_sibling_with_custom_fee() {
434428
435429#[ test]
436430fn test_total_fee ( ) {
437- assert_eq ! ( ztg_fee( ) , 92_696_000 ) ;
438- assert_eq ! ( roc_fee( ) , 9_269_600_000 ) ;
431+ assert_eq ! ( ztg_fee( ) , 80_824_000 ) ;
432+ assert_eq ! ( roc_fee( ) , 8_082_400_000 ) ;
439433}
440434
441435#[ inline]
0 commit comments