htlcswitch: update tests to respect recent API changes

This commit is contained in:
Olaoluwa Osuntokun 2018-01-30 20:11:01 -08:00
parent 9c483c38b1
commit 850abbbeb5
No known key found for this signature in database
GPG Key ID: 964EA263DD637C21
2 changed files with 4 additions and 10 deletions

@ -57,13 +57,6 @@ func messageToString(msg lnwire.Message) string {
switch m := msg.(type) { switch m := msg.(type) {
case *lnwire.RevokeAndAck: case *lnwire.RevokeAndAck:
m.NextRevocationKey.Curve = nil m.NextRevocationKey.Curve = nil
case *lnwire.NodeAnnouncement:
m.NodeID.Curve = nil
case *lnwire.ChannelAnnouncement:
m.NodeID1.Curve = nil
m.NodeID2.Curve = nil
m.BitcoinKey1.Curve = nil
m.BitcoinKey2.Curve = nil
case *lnwire.AcceptChannel: case *lnwire.AcceptChannel:
m.FundingKey.Curve = nil m.FundingKey.Curve = nil
m.RevocationPoint.Curve = nil m.RevocationPoint.Curve = nil

@ -48,6 +48,7 @@ var (
R: new(big.Int), R: new(big.Int),
S: new(big.Int), S: new(big.Int),
} }
wireSig, _ = lnwire.NewSigFromSignature(testSig)
_, _ = testSig.R.SetString("6372440660162918006277497454296753625158993"+ _, _ = testSig.R.SetString("6372440660162918006277497454296753625158993"+
"5445068131219452686511677818569431", 10) "5445068131219452686511677818569431", 10)
@ -55,11 +56,11 @@ var (
"3135609736119018462340006816851118", 10) "3135609736119018462340006816851118", 10)
) )
// mockGetChanUpdateMessage helper function which returns topology update // mockGetChanUpdateMessage helper function which returns topology update of
// of the channel // the channel
func mockGetChanUpdateMessage() (*lnwire.ChannelUpdate, error) { func mockGetChanUpdateMessage() (*lnwire.ChannelUpdate, error) {
return &lnwire.ChannelUpdate{ return &lnwire.ChannelUpdate{
Signature: testSig, Signature: wireSig,
}, nil }, nil
} }