package service

import (
	"testing"
	"wallet-server/conf"
)

func TestNode(t *testing.T) {
	err := conf.InitConfig("../conf/conf.yaml")
	if err != nil {
		t.Fatal(err)
	}

	config := conf.GetConfig()
	n, err := NewNode(config.EthRpcAddrs, config.TronRpcAddrs)
	if err != nil {
		t.Fatal(err)
	}

	t.Log("eth block number", n.ethBlockNumber)
	t.Log("tron block number", n.tronBlockNumber)

	n.ethClient.Close()
	n.tronClient.Stop()
}
