lbry.go/lbrycrd/address_test.go

15 lines
321 B
Go
Raw Normal View History

package lbrycrd
import "testing"
func TestDecodeAddress(t *testing.T) {
addr := "bMUxfQVUeDi7ActVeZJZHzHKBceai7kHha"
btcAddr, err := DecodeAddress(addr, &MainNetParams)
if err != nil {
t.Error(err)
}
2022-10-14 20:24:17 +02:00
if btcAddr.EncodeAddress() != addr {
t.Errorf("expected: %s, actual: %s", addr, btcAddr.EncodeAddress())
}
}