From 812947cc2471ad7cd1c88015ef1a57a26f9d4a9e Mon Sep 17 00:00:00 2001 From: FP Date: Wed, 6 Mar 2024 09:55:13 -0800 Subject: [PATCH] fix: ape build --- ape-config.yaml | 9 +-------- requirements.txt | 8 +++++++- tests/manager/test_role_manager.py | 30 +++++++++++++++--------------- 3 files changed, 23 insertions(+), 24 deletions(-) diff --git a/ape-config.yaml b/ape-config.yaml index d423b00..e68086e 100644 --- a/ape-config.yaml +++ b/ape-config.yaml @@ -1,12 +1,5 @@ name: yearn-v3-vault-periphery -plugins: - - name: solidity - - name: vyper - - name: etherscan - - name: hardhat - - name: infura - default_ecosystem: ethereum dependencies: @@ -43,4 +36,4 @@ solidity: ethereum: local: - default_provider: hardhat \ No newline at end of file + default_provider: hardhat diff --git a/requirements.txt b/requirements.txt index 2c02fbc..aa6835c 100644 --- a/requirements.txt +++ b/requirements.txt @@ -1,3 +1,9 @@ black==22.3.0 eth-ape==0.7.9 -pysha3==1.0.2 \ No newline at end of file +pysha3==1.0.2 +ape-solidity +ape-vyper +ape-etherscan +ape-hardhat +ape-infura +ape-foundry diff --git a/tests/manager/test_role_manager.py b/tests/manager/test_role_manager.py index 42e61cb..54d68ee 100644 --- a/tests/manager/test_role_manager.py +++ b/tests/manager/test_role_manager.py @@ -261,7 +261,7 @@ def test_setters_with_zeros( tx = role_manager.newVault(asset, int(1), sender=daddy) event = list(tx.decode_logs(registry.NewEndorsedVault))[0] - vault = project.dependencies["yearn-vaults"]["master"].VaultV3.at(event.vault) + vault = project.dependencies["yearn-vaults"]["v3.0.2"].VaultV3.at(event.vault) assert vault != ZERO_ADDRESS @@ -323,7 +323,7 @@ def test_deploy_new_vault( event = list(tx.decode_logs(registry.NewEndorsedVault))[0] - vault = project.dependencies["yearn-vaults"]["master"].VaultV3.at(event.vault) + vault = project.dependencies["yearn-vaults"]["v3.0.2"].VaultV3.at(event.vault) event = list(tx.decode_logs(role_manager.AddedNewVault))[0] @@ -418,7 +418,7 @@ def test_deploy_new_vault__duplicate_reverts( event = list(tx.decode_logs(registry.NewEndorsedVault))[0] - vault = project.dependencies["yearn-vaults"]["master"].VaultV3.at(event.vault) + vault = project.dependencies["yearn-vaults"]["v3.0.2"].VaultV3.at(event.vault) event = list(tx.decode_logs(debt_allocator_factory.NewDebtAllocator))[0] @@ -506,7 +506,7 @@ def test_deploy_new_vault__default_values( event = list(tx.decode_logs(registry.NewEndorsedVault))[0] - vault = project.dependencies["yearn-vaults"]["master"].VaultV3.at(event.vault) + vault = project.dependencies["yearn-vaults"]["v3.0.2"].VaultV3.at(event.vault) event = list(tx.decode_logs(role_manager.AddedNewVault))[0] @@ -613,7 +613,7 @@ def test_add_new_vault__endorsed( tx = registry.newEndorsedVault(asset, name, symbol, daddy, 100, sender=daddy) event = list(tx.decode_logs(registry.NewEndorsedVault))[0] - vault = project.dependencies["yearn-vaults"]["master"].VaultV3.at(event.vault) + vault = project.dependencies["yearn-vaults"]["v3.0.2"].VaultV3.at(event.vault) assert registry.numAssets() == 1 assert registry.numEndorsedVaults(asset) == 1 @@ -713,7 +713,7 @@ def test_add_new_vault__not_endorsed( tx = vault_factory.deploy_new_vault(asset, name, symbol, daddy, 100, sender=daddy) event = list(tx.decode_logs(vault_factory.NewVault))[0] - vault = project.dependencies["yearn-vaults"]["master"].VaultV3.at( + vault = project.dependencies["yearn-vaults"]["v3.0.2"].VaultV3.at( event.vault_address ) @@ -822,7 +822,7 @@ def test_add_new_vault__with_debt_allocator( tx = vault_factory.deploy_new_vault(asset, name, symbol, daddy, 100, sender=daddy) event = list(tx.decode_logs(vault_factory.NewVault))[0] - vault = project.dependencies["yearn-vaults"]["master"].VaultV3.at( + vault = project.dependencies["yearn-vaults"]["v3.0.2"].VaultV3.at( event.vault_address ) @@ -931,7 +931,7 @@ def test_add_new_vault__with_accountant( tx = vault_factory.deploy_new_vault(asset, name, symbol, daddy, 100, sender=daddy) event = list(tx.decode_logs(vault_factory.NewVault))[0] - vault = project.dependencies["yearn-vaults"]["master"].VaultV3.at( + vault = project.dependencies["yearn-vaults"]["v3.0.2"].VaultV3.at( event.vault_address ) @@ -1051,7 +1051,7 @@ def test_add_new_vault__duplicate_reverts( event = list(tx.decode_logs(registry.NewEndorsedVault))[0] - vault = project.dependencies["yearn-vaults"]["master"].VaultV3.at(event.vault) + vault = project.dependencies["yearn-vaults"]["v3.0.2"].VaultV3.at(event.vault) event = list(tx.decode_logs(debt_allocator_factory.NewDebtAllocator))[0] @@ -1083,7 +1083,7 @@ def test_add_new_vault__duplicate_reverts( tx = vault_factory.deploy_new_vault(asset, name, symbol, daddy, 100, sender=daddy) event = list(tx.decode_logs(vault_factory.NewVault))[0] - new_vault = project.dependencies["yearn-vaults"]["master"].VaultV3.at( + new_vault = project.dependencies["yearn-vaults"]["v3.0.2"].VaultV3.at( event.vault_address ) @@ -1128,7 +1128,7 @@ def test_new_debt_allocator__deploys_one( tx = role_manager.newVault(asset, category, sender=daddy) event = list(tx.decode_logs(registry.NewEndorsedVault))[0] - vault = project.dependencies["yearn-vaults"]["master"].VaultV3.at(event.vault) + vault = project.dependencies["yearn-vaults"]["v3.0.2"].VaultV3.at(event.vault) event = list(tx.decode_logs(debt_allocator_factory.NewDebtAllocator))[0] debt_allocator = project.DebtAllocator.at(event.allocator) @@ -1253,7 +1253,7 @@ def test_new_debt_allocator__already_deployed( tx = role_manager.newVault(asset, category, sender=daddy) event = list(tx.decode_logs(registry.NewEndorsedVault))[0] - vault = project.dependencies["yearn-vaults"]["master"].VaultV3.at(event.vault) + vault = project.dependencies["yearn-vaults"]["v3.0.2"].VaultV3.at(event.vault) event = list(tx.decode_logs(debt_allocator_factory.NewDebtAllocator))[0] debt_allocator = project.DebtAllocator.at(event.allocator) @@ -1378,7 +1378,7 @@ def test_new_keeper( tx = role_manager.newVault(asset, category, sender=daddy) event = list(tx.decode_logs(registry.NewEndorsedVault))[0] - vault = project.dependencies["yearn-vaults"]["master"].VaultV3.at(event.vault) + vault = project.dependencies["yearn-vaults"]["v3.0.2"].VaultV3.at(event.vault) event = list(tx.decode_logs(debt_allocator_factory.NewDebtAllocator))[0] debt_allocator = project.DebtAllocator.at(event.allocator) @@ -1495,7 +1495,7 @@ def test_remove_vault( tx = role_manager.newVault(asset, category, sender=daddy) event = list(tx.decode_logs(registry.NewEndorsedVault))[0] - vault = project.dependencies["yearn-vaults"]["master"].VaultV3.at(event.vault) + vault = project.dependencies["yearn-vaults"]["v3.0.2"].VaultV3.at(event.vault) event = list(tx.decode_logs(debt_allocator_factory.NewDebtAllocator))[0] debt_allocator = project.DebtAllocator.at(event.allocator) @@ -1626,7 +1626,7 @@ def test_remove_role( tx = role_manager.newVault(asset, category, sender=daddy) event = list(tx.decode_logs(registry.NewEndorsedVault))[0] - vault = project.dependencies["yearn-vaults"]["master"].VaultV3.at(event.vault) + vault = project.dependencies["yearn-vaults"]["v3.0.2"].VaultV3.at(event.vault) event = list(tx.decode_logs(debt_allocator_factory.NewDebtAllocator))[0] debt_allocator = project.DebtAllocator.at(event.allocator)