Skip to content

Commit

Permalink
fix build
Browse files Browse the repository at this point in the history
  • Loading branch information
AStox committed Jul 30, 2024
1 parent 1c2bbbb commit b809f8b
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 7 deletions.
5 changes: 3 additions & 2 deletions src/spell/MigrationSpell-mainnet.sol
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ import {RestrictionUpdate} from "src/interfaces/token/IRestrictionManager.sol";
import {ITranche} from "src/interfaces/token/ITranche.sol";
import {IInvestmentManager} from "src/interfaces/IInvestmentManager.sol";
import {CastLib} from "src/libraries/CastLib.sol";
import {IAuth} from "src/interfaces/IAuth.sol";

interface ITrancheOld {
function authTransferFrom(address from, address to, uint256 value) external returns (bool);
Expand Down Expand Up @@ -130,8 +131,8 @@ contract MigrationSpell {
rootNew.denyContract(address(POOLMANAGER), self);
rootNew.denyContract(address(trancheTokenNew), self);
rootOld.denyContract(address(investmentManagerOld), self);
rootOld.deny(self);
rootNew.deny(self);
IAuth(address(rootOld)).deny(self);
IAuth(address(rootNew)).deny(self);
}

function getNumberOfMigratedMembers() public view returns (uint256) {
Expand Down
11 changes: 6 additions & 5 deletions src/spell/MigrationSpell.t.sol
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
pragma solidity 0.8.26;

import {Guardian} from "src/admin/Guardian.sol";
import {Auth} from "src/Auth.sol";
import "./MigrationSpell-mainnet.sol";
import "forge-std/Test.sol";
import "forge-std/StdJson.sol";
Expand Down Expand Up @@ -75,11 +76,11 @@ contract MigrationSpellTest is Test {
assertEq(trancheTokenOld.symbol(), spell.SYMBOL_OLD());

// assert denies
assertEq(spell.POOLMANAGER().wards(address(spell)), 0);
assertEq(spell.trancheTokenNew().wards(address(spell)), 0);
assertEq(spell.INVESTMENTMANAGER_OLD().wards(address(spell)), 0);
assertEq(spell.ROOT_OLD().wards(address(spell)), 0);
assertEq(spell.ROOT_NEW().wards(address(spell)), 0);
assertEq(Auth(spell.POOLMANAGER()).wards(address(spell)), 0);
assertEq(Auth(address(spell.trancheTokenNew())).wards(address(spell)), 0);
assertEq(Auth(spell.INVESTMENTMANAGER_OLD()).wards(address(spell)), 0);
assertEq(Auth(spell.ROOT_OLD()).wards(address(spell)), 0);
assertEq(Auth(spell.ROOT_NEW()).wards(address(spell)), 0);
}

function _loadDeployment(string memory folder, string memory name) internal {
Expand Down

0 comments on commit b809f8b

Please sign in to comment.