mirror of https://github.com/embarklabs/embark.git
convert test_app contracts config from json format to js object
This commit is contained in:
parent
b804f51de5
commit
24eadbd94f
|
@ -1,97 +1,97 @@
|
||||||
module.exports = {
|
module.exports = {
|
||||||
"default": {
|
default: {
|
||||||
"deployment": {
|
deployment: {
|
||||||
"host": "localhost",
|
host: "localhost",
|
||||||
"port": 8545,
|
port: 8545,
|
||||||
"type": "rpc"
|
type: "rpc"
|
||||||
},
|
},
|
||||||
"dappConnection": [
|
dappConnection: [
|
||||||
"$WEB3",
|
"$WEB3",
|
||||||
"ws://localhost:8546",
|
"ws://localhost:8546",
|
||||||
"http://localhost:8550",
|
"http://localhost:8550",
|
||||||
"http://localhost:8545",
|
"http://localhost:8545",
|
||||||
"http://localhost:8550"
|
"http://localhost:8550"
|
||||||
],
|
],
|
||||||
"gas": "auto",
|
gas: "auto",
|
||||||
"contracts": {
|
contracts: {
|
||||||
"Ownable": {
|
Ownable: {
|
||||||
"deploy": false
|
deploy: false
|
||||||
},
|
},
|
||||||
"SimpleStorage": {
|
SimpleStorage: {
|
||||||
"fromIndex": 0,
|
fromIndex: 0,
|
||||||
"args": [
|
args: [
|
||||||
100
|
100
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
"AnotherStorage": {
|
AnotherStorage: {
|
||||||
"args": [
|
args: [
|
||||||
"$SimpleStorage"
|
"$SimpleStorage"
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
"Token": {
|
Token: {
|
||||||
"deploy": false,
|
deploy: false,
|
||||||
"args": [1000]
|
args: [1000]
|
||||||
},
|
},
|
||||||
"Test": {
|
Test: {
|
||||||
"onDeploy": [
|
onDeploy: [
|
||||||
"Test.methods.changeAddress('$MyToken')"
|
"Test.methods.changeAddress('$MyToken')"
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
"MyToken": {
|
MyToken: {
|
||||||
"instanceOf": "Token"
|
instanceOf: "Token"
|
||||||
},
|
},
|
||||||
"MyToken2": {
|
MyToken2: {
|
||||||
"instanceOf": "Token",
|
instanceOf: "Token",
|
||||||
"args": [200]
|
args: [200]
|
||||||
},
|
},
|
||||||
"AlreadyDeployedToken": {
|
AlreadyDeployedToken: {
|
||||||
"address": "0xece374063fe5cc7efbaca0a498477cada94e5ad6",
|
address: "0xece374063fe5cc7efbaca0a498477cada94e5ad6",
|
||||||
"instanceOf": "Token"
|
instanceOf: "Token"
|
||||||
},
|
},
|
||||||
"MyToken3": {
|
MyToken3: {
|
||||||
"instanceOf": "Tokn"
|
instanceOf: "Tokn"
|
||||||
},
|
},
|
||||||
"ContractArgs": {
|
ContractArgs: {
|
||||||
"args": {
|
args: {
|
||||||
"initialValue": 123,
|
initialValue: 123,
|
||||||
"_addresses": ["$MyToken2", "$SimpleStorage"]
|
"_addresses": ["$MyToken2", "$SimpleStorage"]
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"SomeContract": {
|
SomeContract: {
|
||||||
"args": [
|
args: [
|
||||||
["$MyToken2", "$SimpleStorage"],
|
["$MyToken2", "$SimpleStorage"],
|
||||||
100
|
100
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
"ERC20": {
|
ERC20: {
|
||||||
"file": "zeppelin-solidity/contracts/token/ERC20/ERC20.sol"
|
file: "zeppelin-solidity/contracts/token/ERC20/ERC20.sol"
|
||||||
},
|
},
|
||||||
"SimpleStorageTest": {
|
SimpleStorageTest: {
|
||||||
"file": "./some_folder/test_contract.sol",
|
file: "./some_folder/test_contract.sol",
|
||||||
"args": [
|
args: [
|
||||||
1000
|
1000
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
"Identity": {
|
Identity: {
|
||||||
"file": "https://github.com/status-im/contracts/blob/master/contracts/identity/Identity.sol"
|
file: "https://github.com/status-im/contracts/blob/master/contracts/identity/Identity.sol"
|
||||||
},
|
},
|
||||||
"SimpleStorageWithHttpImport": {
|
SimpleStorageWithHttpImport: {
|
||||||
"fromIndex": 0,
|
fromIndex: 0,
|
||||||
"args": [
|
args: [
|
||||||
100
|
100
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"afterDeploy": [
|
afterDeploy: [
|
||||||
"Test.methods.changeAddress('$MyToken')",
|
"Test.methods.changeAddress('$MyToken')",
|
||||||
"web3.eth.getAccounts((err, accounts) => Test.methods.changeAddress(accounts[0]))"
|
"web3.eth.getAccounts((err, accounts) => Test.methods.changeAddress(accounts[0]))"
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
"development": {
|
development: {
|
||||||
"contracts": {
|
contracts: {
|
||||||
"MyToken2": {
|
MyToken2: {
|
||||||
"instanceOf": "Token",
|
instanceOf: "Token",
|
||||||
"args": [2000]
|
args: [2000]
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue