Skip to content

Commit

Permalink
Merge remote-tracking branch 'refs/remotes/ethereum/master'
Browse files Browse the repository at this point in the history
  • Loading branch information
chrisfranko committed Apr 19, 2017
2 parents e5efa50 + 1cf2ee4 commit fd5b131
Show file tree
Hide file tree
Showing 9 changed files with 121 additions and 119 deletions.
14 changes: 11 additions & 3 deletions build/ci.go
Original file line number Diff line number Diff line change
Expand Up @@ -217,9 +217,16 @@ func doInstall(cmdline []string) {
}

func buildFlags(env build.Environment) (flags []string) {
// Set gitCommit constant via link-time assignment.
var ld []string
if env.Commit != "" {
flags = append(flags, "-ldflags", "-X main.gitCommit="+env.Commit)
ld = append(ld, "-X", "main.gitCommit="+env.Commit)
}
if runtime.GOOS == "darwin" {
ld = append(ld, "-s")
}

if len(ld) > 0 {
flags = append(flags, "-ldflags", strings.Join(ld, " "))
}
return flags
}
Expand Down Expand Up @@ -266,6 +273,7 @@ func doTest(cmdline []string) {
coverage = flag.Bool("coverage", false, "Whether to record code coverage")
)
flag.CommandLine.Parse(cmdline)
env := build.Env()

packages := []string{"./..."}
if len(flag.CommandLine.Args()) > 0 {
Expand All @@ -279,7 +287,7 @@ func doTest(cmdline []string) {
spellcheck(packages)
}
// Run the actual tests.
gotest := goTool("test")
gotest := goTool("test", buildFlags(env)...)
// Test a single package at a time. CI builders are slow
// and some tests run into timeouts under load.
gotest.Args = append(gotest.Args, "-p", "1")
Expand Down
66 changes: 32 additions & 34 deletions core/gen_genesis.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

26 changes: 11 additions & 15 deletions core/gen_genesis_account.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 3 additions & 3 deletions core/genesis.go
Original file line number Diff line number Diff line change
Expand Up @@ -58,10 +58,10 @@ type GenesisAlloc map[common.Address]GenesisAccount

// GenesisAccount is an account in the state of the genesis block.
type GenesisAccount struct {
Code []byte `json:"code" optional:"true"`
Storage map[common.Hash]common.Hash `json:"storage" optional:"true"`
Code []byte `json:"code,omitempty" optional:"true"`
Storage map[common.Hash]common.Hash `json:"storage,omitempty" optional:"true"`
Balance *big.Int `json:"balance"`
Nonce uint64 `json:"nonce" optional:"true"`
Nonce uint64 `json:"nonce,omitempty" optional:"true"`
}

// field type overrides for gencodec
Expand Down
52 changes: 26 additions & 26 deletions core/types/gen_header_json.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

36 changes: 18 additions & 18 deletions core/types/gen_log_json.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

24 changes: 12 additions & 12 deletions core/types/gen_receipt_json.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading

0 comments on commit fd5b131

Please sign in to comment.