mirror of
https://github.com/fluencelabs/tendermint
synced 2025-06-21 17:01:35 +00:00
fix node/addrbook test; made build task quieter
This commit is contained in:
2
Makefile
2
Makefile
@ -28,7 +28,7 @@ build_race:
|
|||||||
|
|
||||||
test: build
|
test: build
|
||||||
-rm -rf ~/.tendermint_test_bak
|
-rm -rf ~/.tendermint_test_bak
|
||||||
-mv ~/.tendermint_test ~/.tendermint_test_bak
|
-mv ~/.tendermint_test ~/.tendermint_test_bak && true
|
||||||
go test github.com/tendermint/tendermint/...
|
go test github.com/tendermint/tendermint/...
|
||||||
|
|
||||||
draw_deps:
|
draw_deps:
|
||||||
|
@ -31,7 +31,6 @@ func initTMRoot(rootDir string) {
|
|||||||
|
|
||||||
configFilePath := path.Join(rootDir, "config.toml")
|
configFilePath := path.Join(rootDir, "config.toml")
|
||||||
genesisFilePath := path.Join(rootDir, "genesis.json")
|
genesisFilePath := path.Join(rootDir, "genesis.json")
|
||||||
privValFilePath := path.Join(rootDir, "priv_validator.json")
|
|
||||||
|
|
||||||
// Write default config file if missing.
|
// Write default config file if missing.
|
||||||
if !FileExists(configFilePath) {
|
if !FileExists(configFilePath) {
|
||||||
@ -42,9 +41,6 @@ func initTMRoot(rootDir string) {
|
|||||||
if !FileExists(genesisFilePath) {
|
if !FileExists(genesisFilePath) {
|
||||||
MustWriteFile(genesisFilePath, []byte(defaultGenesis))
|
MustWriteFile(genesisFilePath, []byte(defaultGenesis))
|
||||||
}
|
}
|
||||||
if !FileExists(privValFilePath) {
|
|
||||||
MustWriteFile(privValFilePath, []byte(privValFilePath))
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
func GetConfig(rootDir string) cfg.Config {
|
func GetConfig(rootDir string) cfg.Config {
|
||||||
|
@ -4,16 +4,10 @@ import (
|
|||||||
"testing"
|
"testing"
|
||||||
"time"
|
"time"
|
||||||
|
|
||||||
cfg "github.com/tendermint/tendermint/config"
|
_ "github.com/tendermint/tendermint/config/tendermint_test"
|
||||||
tmcfg "github.com/tendermint/tendermint/config/tendermint"
|
|
||||||
"github.com/tendermint/tendermint/p2p"
|
"github.com/tendermint/tendermint/p2p"
|
||||||
)
|
)
|
||||||
|
|
||||||
func init() {
|
|
||||||
config := tmcfg.GetConfig("")
|
|
||||||
cfg.ApplyConfig(config)
|
|
||||||
}
|
|
||||||
|
|
||||||
func TestNodeStartStop(t *testing.T) {
|
func TestNodeStartStop(t *testing.T) {
|
||||||
// Create & start node
|
// Create & start node
|
||||||
n := NewNode()
|
n := NewNode()
|
||||||
|
Reference in New Issue
Block a user