Deploying locally & conclusion
#
TestingWith our recipe complete, let's test the Polywrapper on our local environment! First, let's set up our test environment with the following command in your terminal:
tip
Next, we will deploy our both our SimpleStorage.sol
smart contract as well as our Polywrapper with the following command:
tip
Behind the scenes, yarn deploy
will run the following commands:
Let's break down each of these commands, starting with yarn deploy:contract
, which itself runs this command:
In the above command, we are executing a custom script, deploy-contract.js
that deploys Simple Storage smart contract at a specific address on our test network. We'll be interacting with this deployed smart contract using our Polywrapper.
Next, our command will build and deploy the Polywrapper:
This will deploy the Polywrapper on an Ethereum Name Service (ENS) domain registered in the test environment that is set to resolve to a local IPFS node.
Now, we'll use the following command to check whether our Polywrapper and smart contract are working properly:
This command uses our custom query
CLI command, which will execute a series of Polywrap queries and mutations and return the result to you.
#
Conclusion๐ Congratulations! You've create a custom Polywrap!
Hopefully this article has given you a clear understanding of the Polywrap toolchain's primary features. If at any time in this process you get stuck or have questions, please don't hesitate to reach out on Discord.