Beispiel #1
0
func TestMain(m *testing.M) {
	config.SetupTestConfig("./../..")

	tmpConn, err := NewPeerClientConnection()
	if err != nil {
		fmt.Printf("error connection to server at host:port = %s\n", viper.GetString("peer.address"))
		os.Exit(1)
	}
	peerClientConn = tmpConn
	os.Exit(m.Run())
}
Beispiel #2
0
func TestMain(m *testing.M) {
	config.SetupTestConfig("./../..")
	viper.Set("ledger.blockchain.deploy-system-chaincode", "false")
	viper.Set("peer.validator.validity-period.verification", "false")

	tmpConn, err := NewPeerClientConnection()
	if err != nil {
		fmt.Printf("error connection to server at host:port = %s\n", viper.GetString("peer.address"))
		os.Exit(1)
	}
	peerClientConn = tmpConn
	os.Exit(m.Run())
}