Skip to content

Commit

Permalink
fix: deployments
Browse files Browse the repository at this point in the history
  • Loading branch information
Schlagonia committed Dec 15, 2023
1 parent cda3434 commit e048be1
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 18 deletions.
5 changes: 3 additions & 2 deletions contracts/debtAllocators/YieldManager/YieldManager.sol
Original file line number Diff line number Diff line change
Expand Up @@ -69,9 +69,10 @@ contract YieldManager is Governance {

constructor(
address _governance,
address _strategyManager
bytes4[] memory _selectors
) Governance(_governance) {
strategyManager = _strategyManager;
// Deploy a new strategy manager
strategyManager = address(new StrategyManager(_governance, _selectors));
// Default to 1 BP loss
maxDebtUpdateLoss = 1;
}
Expand Down
22 changes: 6 additions & 16 deletions tests/conftest.py
Original file line number Diff line number Diff line change
Expand Up @@ -410,28 +410,18 @@ def generic_debt_allocator(generic_debt_allocator_factory, project, vault, daddy


@pytest.fixture(scope="session")
def deploy_strategy_manager(project, daddy):
def deploy_strategy_manager():
strategy_manager = daddy.deploy(
project.StrategyManager, daddy, ["0x2606a10b", "0xdf69b22a"]
)

return strategy_manager

yield deploy_strategy_manager


@pytest.fixture(scope="session")
def strategy_manager(deploy_strategy_manager):
strategy_manager = deploy_strategy_manager()
def strategy_manager(project, yield_manager):
strategy_manager = project.StrategyManager.at(yield_manager.strategyManager())

yield strategy_manager


@pytest.fixture(scope="session")
def deploy_yield_manager(project, daddy, strategy_manager):
def deploy_yield_manager(project, daddy):
def deploy_yield_manager():
yield_manager = daddy.deploy(project.YieldManager, daddy, strategy_manager)
yield_manager = daddy.deploy(
project.YieldManager, daddy, ["0x2606a10b", "0xdf69b22a"]
)

return yield_manager

Expand Down

0 comments on commit e048be1

Please sign in to comment.