-
Notifications
You must be signed in to change notification settings - Fork 99
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
9a0c902
commit 8fbec7f
Showing
199 changed files
with
2,406 additions
and
2,023 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
243 changes: 121 additions & 122 deletions
243
contracts/examples/crowdfunding-erc20/mandos/deploy_erc20_and_crowdfunding.scen.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,131 +1,130 @@ | ||
{ | ||
"name": "deploy erc20 and give its address to the crowdfunding contract", | ||
"steps": [ | ||
{ | ||
"step": "setState", | ||
"accounts": { | ||
"address:erc20_owner": { | ||
"nonce": "0", | ||
"balance": "0", | ||
"storage": {} | ||
}, | ||
"address:crowdfunding_owner": { | ||
"nonce": "0", | ||
"balance": "0", | ||
"storage": {} | ||
} | ||
}, | ||
"newAddresses": [ | ||
{ | ||
"creatorAddress": "address:erc20_owner", | ||
"creatorNonce": "0", | ||
"newAddress": "sc:erc20" | ||
}, | ||
{ | ||
"creatorAddress": "address:crowdfunding_owner", | ||
"creatorNonce": "0", | ||
"newAddress": "sc:crowdfunding" | ||
} | ||
] | ||
}, | ||
{ | ||
"step": "scDeploy", | ||
"txId": "deploy", | ||
"tx": { | ||
"from": "address:erc20_owner", | ||
"contractCode": "file:../../erc20/output/erc20.wasm", | ||
"value": "0", | ||
"arguments": [ | ||
"1,000,000,000" | ||
], | ||
"gasLimit": "50,000,000", | ||
"gasPrice": "0" | ||
}, | ||
"expect": { | ||
"status": "0", | ||
"gas": "*", | ||
"refund": "*" | ||
} | ||
}, | ||
{ | ||
"step": "checkState", | ||
"accounts": { | ||
"address:erc20_owner": { | ||
"nonce": "1", | ||
"balance": "0", | ||
"storage": {} | ||
}, | ||
"address:crowdfunding_owner": { | ||
"nonce": "0", | ||
"balance": "0", | ||
"storage": {} | ||
}, | ||
"sc:erc20": { | ||
"nonce": "0", | ||
"balance": "0", | ||
"storage": { | ||
"str:balance|address:erc20_owner": "1,000,000,000", | ||
"str:totalSupply": "1,000,000,000" | ||
{ | ||
"step": "setState", | ||
"accounts": { | ||
"address:erc20_owner": { | ||
"nonce": "0", | ||
"balance": "0", | ||
"storage": {} | ||
}, | ||
"address:crowdfunding_owner": { | ||
"nonce": "0", | ||
"balance": "0", | ||
"storage": {} | ||
} | ||
}, | ||
"code": "file:../../erc20/output/erc20.wasm" | ||
} | ||
} | ||
}, | ||
{ | ||
"step": "scDeploy", | ||
"txId": "deploy", | ||
"tx": { | ||
"from": "address:crowdfunding_owner", | ||
"contractCode": "file:../output/crowdfunding-erc20.wasm", | ||
"value": "0", | ||
"arguments": [ | ||
"1,000,000", | ||
"123,456", | ||
"sc:erc20" | ||
], | ||
"gasLimit": "50,000,000", | ||
"gasPrice": "0" | ||
"newAddresses": [ | ||
{ | ||
"creatorAddress": "address:erc20_owner", | ||
"creatorNonce": "0", | ||
"newAddress": "sc:erc20" | ||
}, | ||
{ | ||
"creatorAddress": "address:crowdfunding_owner", | ||
"creatorNonce": "0", | ||
"newAddress": "sc:crowdfunding" | ||
} | ||
] | ||
}, | ||
"expect": { | ||
"status": "0", | ||
"gas": "*", | ||
"refund": "*" | ||
} | ||
}, | ||
{ | ||
"step": "checkState", | ||
"accounts": { | ||
"address:erc20_owner": { | ||
"nonce": "1", | ||
"balance": "0", | ||
"storage": {} | ||
}, | ||
"address:crowdfunding_owner": { | ||
"nonce": "1", | ||
"balance": "0", | ||
"storage": {} | ||
}, | ||
"sc:erc20": { | ||
"nonce": "0", | ||
"balance": "0", | ||
"storage": { | ||
"str:balance|address:erc20_owner": "1,000,000,000", | ||
"str:totalSupply": "1,000,000,000" | ||
{ | ||
"step": "scDeploy", | ||
"txId": "deploy", | ||
"tx": { | ||
"from": "address:erc20_owner", | ||
"contractCode": "file:../../erc20/output/erc20.wasm", | ||
"value": "0", | ||
"arguments": [ | ||
"1,000,000,000" | ||
], | ||
"gasLimit": "50,000,000", | ||
"gasPrice": "0" | ||
}, | ||
"code": "file:../../erc20/output/erc20.wasm" | ||
}, | ||
"sc:crowdfunding": { | ||
"nonce": "0", | ||
"balance": "0", | ||
"storage": { | ||
"str:target": "1,000,000", | ||
"str:deadline": "123,456", | ||
"str:erc20ContractAddress": "sc:erc20" | ||
"expect": { | ||
"status": "0", | ||
"gas": "*", | ||
"refund": "*" | ||
} | ||
}, | ||
{ | ||
"step": "checkState", | ||
"accounts": { | ||
"address:erc20_owner": { | ||
"nonce": "1", | ||
"balance": "0", | ||
"storage": {} | ||
}, | ||
"address:crowdfunding_owner": { | ||
"nonce": "0", | ||
"balance": "0", | ||
"storage": {} | ||
}, | ||
"sc:erc20": { | ||
"nonce": "0", | ||
"balance": "0", | ||
"storage": { | ||
"str:balance|address:erc20_owner": "1,000,000,000", | ||
"str:totalSupply": "1,000,000,000" | ||
}, | ||
"code": "file:../../erc20/output/erc20.wasm" | ||
} | ||
} | ||
}, | ||
{ | ||
"step": "scDeploy", | ||
"txId": "deploy", | ||
"tx": { | ||
"from": "address:crowdfunding_owner", | ||
"contractCode": "file:../output/crowdfunding-erc20.wasm", | ||
"value": "0", | ||
"arguments": [ | ||
"1,000,000", | ||
"123,456", | ||
"sc:erc20" | ||
], | ||
"gasLimit": "50,000,000", | ||
"gasPrice": "0" | ||
}, | ||
"code": "file:../output/crowdfunding-erc20.wasm" | ||
} | ||
"expect": { | ||
"status": "0", | ||
"gas": "*", | ||
"refund": "*" | ||
} | ||
}, | ||
{ | ||
"step": "checkState", | ||
"accounts": { | ||
"address:erc20_owner": { | ||
"nonce": "1", | ||
"balance": "0", | ||
"storage": {} | ||
}, | ||
"address:crowdfunding_owner": { | ||
"nonce": "1", | ||
"balance": "0", | ||
"storage": {} | ||
}, | ||
"sc:erc20": { | ||
"nonce": "0", | ||
"balance": "0", | ||
"storage": { | ||
"str:balance|address:erc20_owner": "1,000,000,000", | ||
"str:totalSupply": "1,000,000,000" | ||
}, | ||
"code": "file:../../erc20/output/erc20.wasm" | ||
}, | ||
"sc:crowdfunding": { | ||
"nonce": "0", | ||
"balance": "0", | ||
"storage": { | ||
"str:target": "1,000,000", | ||
"str:deadline": "123,456", | ||
"str:erc20ContractAddress": "sc:erc20" | ||
}, | ||
"code": "file:../output/crowdfunding-erc20.wasm" | ||
} | ||
} | ||
} | ||
} | ||
] | ||
} | ||
|
||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.