-
Notifications
You must be signed in to change notification settings - Fork 113
/
Copy pathtruffle.js
94 lines (91 loc) · 2.09 KB
/
truffle.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
require("@babel/register");
require("@babel/polyfill");
const HDWalletProvider = require("truffle-hdwallet-provider");
const ganache = require("ganache-core");
const ganacheProvider = ganache.provider({ total_accounts: 14, seed: "smoketest" });
const DISABLE_DOCKER = !process.env.DISABLE_DOCKER;
module.exports = {
networks: {
development: {
host: "localhost",
port: 8545,
gasPrice: 0,
network_id: "*",
skipDryRun: true,
},
integration: {
host: "localhost",
port: 8545,
gasPrice: 0,
network_id: 1998,
skipDryRun: true,
},
coverage: {
host: "localhost",
port: 8555,
network_id: parseInt(process.env.CHAIN_ID, 10) || 1999,
skipDryRun: true,
},
goerliFork: {
host: "localhost",
port: 8605,
gasPrice: 0,
network_id: "5",
},
mainnetFork: {
host: "localhost",
port: 8601,
gasPrice: 0,
network_id: "1",
},
mainnet: {
provider: () => {
return new HDWalletProvider("private-key", "https://mainnet.infura.io/v3/infura-key");
},
network_id: "1",
},
goerli: {
provider: () => {
return new HDWalletProvider("private-key", "https://goerli.infura.io/v3/infura-key");
},
network_id: "5",
},
xdai: {
provider: () => {
return new HDWalletProvider("private-key", "https://xdai-archive.blockscout.com/");
},
network_id: "100",
},
storageSmoke: {
provider: () => {
return ganacheProvider;
},
network_id: "*",
},
},
mocha: {
reporter: "mocha-circleci-reporter",
reporterOptions: {
currency: "USD",
gasPrice: 5,
onlyCalledMethods: true,
excludeContracts: ["Migrations"],
},
slow: 1000,
},
compilers: {
solc: {
version: "0.7.3",
docker: DISABLE_DOCKER,
parser: "solcjs",
settings: {
optimizer: {
enabled: true,
runs: 200,
},
evmVersion: "istanbul",
},
},
},
plugins: ["truffle-security", "solidity-coverage"],
};