I am using the Truffle upgrades plugin, "@openzeppelin/truffle-upgrades": "^1.0.2". The problem I’m facing is that for every proxy deployment in my tests (ProxyAdmin, AdminUpgradeabilityProxy), I cannot specify the from address.
The issue with this is that I want to programmatically call the ProxyAdmin contract with my admin account. By using the plugin’s default deployer, it selects a different deployer address than what Truffle is returning me.
This is the current code that I am using in my tests:
deployProxy uses the default account (accounts[0]) to deploy the implementation contract, the ProxyAdmin and the proxy.
There currently isn’t a way to specify the account being used to do this deployment but we also don’t have access other than via the API ( admin.changeAdminForProxy and admin.transferProxyAdminOwnership) to interact with the ProxyAdmin.
Can you share some more details on what you are trying to test on the ProxyAdmin?
Thanks for your help! I think that answers my question. What I am going to do is to call deployProxy then transfer the ownership to the address I want to test with.
The requirement is that I need to test with a specific address, which is why this was a headache. Would be amazing if there was an option to specify this in the future. Nonetheless we can mark this as solved