ethereum / pytest-ethereum

MIT License
19 stars 12 forks source link

Write initial deployer class and fixture #2

Closed njgheorghita closed 5 years ago

njgheorghita commented 6 years ago

What was wrong?

Initial implementation of the Deployer class and related fixture to assist with automatic deployment of contract types.

Issue #

How was it fixed?

Summary of approach.

Cute Animal Picture

image

njgheorghita commented 5 years ago

@pipermerriam pinging for some thoughts on how this should work.

I'm thinking we'll support vyper files or solidity-sourced manifests.

For vyper files, we'll take care of the compilation a la the strategy we paired on last week (probably w/o twig to start and then port compilation over eventually). We'll take care of the compilation/manifest generation/validation, and expose the resulting Deployer from the vy_deployer fixture

A solidity manifest, will require more involvement from the user. But basically they pass the path to the manifest into solc_deployer fixture, which will return the Deployer

You mentioned returning a Package from Deployer.deploy() rather than the created contract instance itself, which I went ahead and made return (Package, deployed_address)