@@ -25,7 +25,7 @@ contract MasterBlueprintServiceManagerTest is Test {
2525 bytes32 public constant PAUSER_ROLE = keccak256 ("PAUSER_ROLE " );
2626 bytes32 public constant TRENCH_UPDATE_ROLE = keccak256 ("TRENCH_UPDATE_ROLE " );
2727
28- address public ROOT_CHAIN = address (0x1111111111111111111111111111111111111111 );
28+ address public ROOT_CHAIN = address (0x09dF6A941ee03B1e632904E382e10862fA9cc0e3 );
2929
3030 uint16 public constant BASE_PERCENT = 10_000 ;
3131
@@ -65,10 +65,10 @@ contract MasterBlueprintServiceManagerTest is Test {
6565 );
6666 event ServiceTerminated (uint64 indexed blueprintId , uint64 indexed serviceId , address owner );
6767 event UnappliedSlash (
68- uint64 indexed blueprintId , uint64 indexed serviceId , bytes offender , uint8 slashPercent , uint256 totalPayout
68+ uint64 indexed blueprintId , uint64 indexed serviceId , bytes offender , uint8 slashPercent
6969 );
7070 event Slashed (
71- uint64 indexed blueprintId , uint64 indexed serviceId , bytes offender , uint8 slashPercent , uint256 totalPayout
71+ uint64 indexed blueprintId , uint64 indexed serviceId , bytes offender , uint8 slashPercent
7272 );
7373
7474 function setUp () public {
@@ -831,7 +831,6 @@ contract MasterBlueprintServiceManagerTest is Test {
831831 uint64 serviceId = 1 ;
832832 bytes memory offender = hex "abcd " ;
833833 uint8 slashPercent = 20 ;
834- uint256 totalPayout = 1000 ether ;
835834
836835 // Create a blueprint first
837836 address owner = address (this );
@@ -856,23 +855,22 @@ contract MasterBlueprintServiceManagerTest is Test {
856855
857856 // Expect the UnappliedSlash event
858857 vm.expectEmit (true , true , false , true );
859- emit UnappliedSlash (blueprintId, serviceId, offender, slashPercent, totalPayout );
858+ emit UnappliedSlash (blueprintId, serviceId, offender, slashPercent);
860859
861- masterManager.onUnappliedSlash (blueprintId, serviceId, offender, slashPercent, totalPayout );
860+ masterManager.onUnappliedSlash (blueprintId, serviceId, offender, slashPercent);
862861 }
863862
864863 function test_onUnappliedSlash_NotFromRootChain () public {
865864 uint64 blueprintId = 1 ;
866865 uint64 serviceId = 1 ;
867866 bytes memory offender = hex "abcd " ;
868867 uint8 slashPercent = 20 ;
869- uint256 totalPayout = 1000 ether ;
870868
871869 vm.expectRevert (
872870 abi.encodeWithSelector (RootChainEnabled.OnlyRootChainAllowed.selector , address (this ), ROOT_CHAIN)
873871 );
874872
875- masterManager.onUnappliedSlash (blueprintId, serviceId, offender, slashPercent, totalPayout );
873+ masterManager.onUnappliedSlash (blueprintId, serviceId, offender, slashPercent);
876874 }
877875
878876 // Test onSlash
@@ -906,23 +904,22 @@ contract MasterBlueprintServiceManagerTest is Test {
906904
907905 // Expect the Slashed event
908906 vm.expectEmit (true , true , false , true );
909- emit Slashed (blueprintId, serviceId, offender, slashPercent, totalPayout );
907+ emit Slashed (blueprintId, serviceId, offender, slashPercent);
910908
911- masterManager.onSlash (blueprintId, serviceId, offender, slashPercent, totalPayout );
909+ masterManager.onSlash (blueprintId, serviceId, offender, slashPercent);
912910 }
913911
914912 function test_onSlash_NotFromRootChain () public {
915913 uint64 blueprintId = 1 ;
916914 uint64 serviceId = 1 ;
917915 bytes memory offender = hex "abcd " ;
918916 uint8 slashPercent = 15 ;
919- uint256 totalPayout = 500 ether ;
920917
921918 vm.expectRevert (
922919 abi.encodeWithSelector (RootChainEnabled.OnlyRootChainAllowed.selector , address (this ), ROOT_CHAIN)
923920 );
924921
925- masterManager.onSlash (blueprintId, serviceId, offender, slashPercent, totalPayout );
922+ masterManager.onSlash (blueprintId, serviceId, offender, slashPercent);
926923 }
927924
928925 // Test querySlashingOrigin
0 commit comments