/
run.go
72 lines (69 loc) · 1.41 KB
/
run.go
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
package run
import (
"github.com/urfave/cli"
)
// Command is the command of run
var Command = cli.Command{
Name: "run",
Usage: "run test by benchmark data",
Flags: Flags,
Subcommands: []cli.Command{
AccountCaseCommand,
AccountRoundCommand,
TransferCaseCommand,
ContractCaseCommand,
CommonVoteCaseCommand,
VoteCaseCommand,
VoteNodeCaseCommand,
BonusCaseCommand,
BenchmarkCommand,
BenchmarkTokenCommand,
BenchmarkToken721Command,
BenchmarkSystemCommand,
BenchmarkAccountCommand,
BenchmarkRPCCommand,
},
}
// Flags is the flags of run command
var Flags = []cli.Flag{
cli.StringFlag{
Name: "keys, k",
Value: "",
Usage: "Load keys from `FILE`",
},
cli.StringFlag{
Name: "config, c",
Value: "",
Usage: "Load itest configuration from `FILE`",
},
cli.StringFlag{
Name: "code",
Value: "",
Usage: "Load contract code from `FILE`",
},
cli.StringFlag{
Name: "abi",
Value: "",
Usage: "Load contract abi from `FILE`",
},
cli.StringFlag{
Name: "account, a",
Value: "accounts.json",
Usage: "The account file that itest would load from if exists",
},
cli.IntFlag{
Name: "anum",
Value: 100,
Usage: "The number of accounts to generated if no given account file",
},
cli.StringFlag{
Name: "aname",
Value: "producer000",
Usage: "The account name to check/run actions",
},
cli.StringFlag{
Name: "log, l",
Value: "itest_logs",
Usage: "log file path",
},
}