mirror of
https://github.com/lightningnetwork/lnd.git
synced 2025-06-03 11:39:52 +02:00
brontide,lnwire,wtwire,zpay32: use CamelCase
Rename fuzz test functions to use CamelCase.
This commit is contained in:
parent
c77852a68c
commit
5a48568806
@ -136,8 +136,8 @@ func getStaticBrontideMachines() (*Machine, *Machine) {
|
||||
return initiator, responder
|
||||
}
|
||||
|
||||
// Fuzz_random_actone fuzz tests ActOne in the brontide handshake.
|
||||
func Fuzz_random_actone(f *testing.F) {
|
||||
// FuzzRandomActOne fuzz tests ActOne in the brontide handshake.
|
||||
func FuzzRandomActOne(f *testing.F) {
|
||||
f.Fuzz(func(t *testing.T, data []byte) {
|
||||
// Check if data is large enough.
|
||||
if len(data) < ActOneSize {
|
||||
@ -158,8 +158,8 @@ func Fuzz_random_actone(f *testing.F) {
|
||||
})
|
||||
}
|
||||
|
||||
// Fuzz_random_actthree fuzz tests ActThree in the brontide handshake.
|
||||
func Fuzz_random_actthree(f *testing.F) {
|
||||
// FuzzRandomActThree fuzz tests ActThree in the brontide handshake.
|
||||
func FuzzRandomActThree(f *testing.F) {
|
||||
f.Fuzz(func(t *testing.T, data []byte) {
|
||||
// Check if data is large enough.
|
||||
if len(data) < ActThreeSize {
|
||||
@ -200,8 +200,8 @@ func Fuzz_random_actthree(f *testing.F) {
|
||||
})
|
||||
}
|
||||
|
||||
// Fuzz_random_acttwo fuzz tests ActTwo in the brontide handshake.
|
||||
func Fuzz_random_acttwo(f *testing.F) {
|
||||
// FuzzRandomActTwo fuzz tests ActTwo in the brontide handshake.
|
||||
func FuzzRandomActTwo(f *testing.F) {
|
||||
f.Fuzz(func(t *testing.T, data []byte) {
|
||||
// Check if data is large enough.
|
||||
if len(data) < ActTwoSize {
|
||||
@ -231,9 +231,9 @@ func Fuzz_random_acttwo(f *testing.F) {
|
||||
})
|
||||
}
|
||||
|
||||
// Fuzz_random_init_decrypt fuzz tests decrypting arbitrary data with the
|
||||
// FuzzRandomInitDecrypt fuzz tests decrypting arbitrary data with the
|
||||
// initiator.
|
||||
func Fuzz_random_init_decrypt(f *testing.F) {
|
||||
func FuzzRandomInitDecrypt(f *testing.F) {
|
||||
f.Fuzz(func(t *testing.T, data []byte) {
|
||||
// This will return brontide machines with random keys.
|
||||
initiator, responder := getBrontideMachines()
|
||||
@ -252,9 +252,9 @@ func Fuzz_random_init_decrypt(f *testing.F) {
|
||||
})
|
||||
}
|
||||
|
||||
// Fuzz_random_init_enc_dec fuzz tests round-trip encryption and decryption
|
||||
// between the initiator and the responder.
|
||||
func Fuzz_random_init_enc_dec(f *testing.F) {
|
||||
// FuzzRandomInitEncDec fuzz tests round-trip encryption and decryption between
|
||||
// the initiator and the responder.
|
||||
func FuzzRandomInitEncDec(f *testing.F) {
|
||||
f.Fuzz(func(t *testing.T, data []byte) {
|
||||
// Ensure that length of message is not greater than max allowed
|
||||
// size.
|
||||
@ -294,9 +294,9 @@ func Fuzz_random_init_enc_dec(f *testing.F) {
|
||||
})
|
||||
}
|
||||
|
||||
// Fuzz_random_init_encrypt fuzz tests the encryption of arbitrary data with
|
||||
// the initiator.
|
||||
func Fuzz_random_init_encrypt(f *testing.F) {
|
||||
// FuzzRandomInitEncrypt fuzz tests the encryption of arbitrary data with the
|
||||
// initiator.
|
||||
func FuzzRandomInitEncrypt(f *testing.F) {
|
||||
f.Fuzz(func(t *testing.T, data []byte) {
|
||||
// Ensure that length of message is not greater than max allowed
|
||||
// size.
|
||||
@ -324,9 +324,9 @@ func Fuzz_random_init_encrypt(f *testing.F) {
|
||||
})
|
||||
}
|
||||
|
||||
// Fuzz_random_resp_decrypt fuzz tests the decryption of arbitrary data with
|
||||
// the responder.
|
||||
func Fuzz_random_resp_decrypt(f *testing.F) {
|
||||
// FuzzRandomRespDecrypt fuzz tests the decryption of arbitrary data with the
|
||||
// responder.
|
||||
func FuzzRandomRespDecrypt(f *testing.F) {
|
||||
f.Fuzz(func(t *testing.T, data []byte) {
|
||||
// This will return brontide machines with random keys.
|
||||
initiator, responder := getBrontideMachines()
|
||||
@ -345,9 +345,9 @@ func Fuzz_random_resp_decrypt(f *testing.F) {
|
||||
})
|
||||
}
|
||||
|
||||
// Fuzz_random_resp_enc_dec fuzz tests round-trip encryption and decryption
|
||||
// between the responder and the initiator.
|
||||
func Fuzz_random_resp_enc_dec(f *testing.F) {
|
||||
// FuzzRandomRespEncDec fuzz tests round-trip encryption and decryption between
|
||||
// the responder and the initiator.
|
||||
func FuzzRandomRespEncDec(f *testing.F) {
|
||||
f.Fuzz(func(t *testing.T, data []byte) {
|
||||
// Ensure that length of message is not greater than max allowed
|
||||
// size.
|
||||
@ -387,9 +387,9 @@ func Fuzz_random_resp_enc_dec(f *testing.F) {
|
||||
})
|
||||
}
|
||||
|
||||
// Fuzz_random_resp_encrypt fuzz tests encryption of arbitrary data with the
|
||||
// FuzzRandomRespEncrypt fuzz tests encryption of arbitrary data with the
|
||||
// responder.
|
||||
func Fuzz_random_resp_encrypt(f *testing.F) {
|
||||
func FuzzRandomRespEncrypt(f *testing.F) {
|
||||
f.Fuzz(func(t *testing.T, data []byte) {
|
||||
// Ensure that length of message is not greater than max allowed
|
||||
// size.
|
||||
@ -417,8 +417,8 @@ func Fuzz_random_resp_encrypt(f *testing.F) {
|
||||
})
|
||||
}
|
||||
|
||||
// Fuzz_static_actone fuzz tests ActOne in the brontide handshake.
|
||||
func Fuzz_static_actone(f *testing.F) {
|
||||
// FuzzStaticActOne fuzz tests ActOne in the brontide handshake.
|
||||
func FuzzStaticActOne(f *testing.F) {
|
||||
f.Fuzz(func(t *testing.T, data []byte) {
|
||||
// Check if data is large enough.
|
||||
if len(data) < ActOneSize {
|
||||
@ -439,8 +439,8 @@ func Fuzz_static_actone(f *testing.F) {
|
||||
})
|
||||
}
|
||||
|
||||
// Fuzz_static_actthree fuzz tests ActThree in the brontide handshake.
|
||||
func Fuzz_static_actthree(f *testing.F) {
|
||||
// FuzzStaticActThree fuzz tests ActThree in the brontide handshake.
|
||||
func FuzzStaticActThree(f *testing.F) {
|
||||
f.Fuzz(func(t *testing.T, data []byte) {
|
||||
// Check if data is large enough.
|
||||
if len(data) < ActThreeSize {
|
||||
@ -481,8 +481,8 @@ func Fuzz_static_actthree(f *testing.F) {
|
||||
})
|
||||
}
|
||||
|
||||
// Fuzz_static_acttwo fuzz tests ActTwo in the brontide handshake.
|
||||
func Fuzz_static_acttwo(f *testing.F) {
|
||||
// FuzzStaticActTwo fuzz tests ActTwo in the brontide handshake.
|
||||
func FuzzStaticActTwo(f *testing.F) {
|
||||
f.Fuzz(func(t *testing.T, data []byte) {
|
||||
// Check if data is large enough.
|
||||
if len(data) < ActTwoSize {
|
||||
@ -512,9 +512,9 @@ func Fuzz_static_acttwo(f *testing.F) {
|
||||
})
|
||||
}
|
||||
|
||||
// Fuzz_static_init_decrypt fuzz tests the decryption of arbitrary data with
|
||||
// the initiator.
|
||||
func Fuzz_static_init_decrypt(f *testing.F) {
|
||||
// FuzzStaticInitDecrypt fuzz tests the decryption of arbitrary data with the
|
||||
// initiator.
|
||||
func FuzzStaticInitDecrypt(f *testing.F) {
|
||||
f.Fuzz(func(t *testing.T, data []byte) {
|
||||
// This will return brontide machines with static keys.
|
||||
initiator, responder := getStaticBrontideMachines()
|
||||
@ -533,9 +533,9 @@ func Fuzz_static_init_decrypt(f *testing.F) {
|
||||
})
|
||||
}
|
||||
|
||||
// Fuzz_static_init_enc_dec fuzz tests round-trip encryption and decryption
|
||||
// between the initiator and the responder.
|
||||
func Fuzz_static_init_enc_dec(f *testing.F) {
|
||||
// FuzzStaticInitEncDec fuzz tests round-trip encryption and decryption between
|
||||
// the initiator and the responder.
|
||||
func FuzzStaticInitEncDec(f *testing.F) {
|
||||
f.Fuzz(func(t *testing.T, data []byte) {
|
||||
// Ensure that length of message is not greater than max allowed
|
||||
// size.
|
||||
@ -576,9 +576,9 @@ func Fuzz_static_init_enc_dec(f *testing.F) {
|
||||
})
|
||||
}
|
||||
|
||||
// Fuzz_static_init_encrypt fuzz tests the encryption of arbitrary data with
|
||||
// the initiator.
|
||||
func Fuzz_static_init_encrypt(f *testing.F) {
|
||||
// FuzzStaticInitEncrypt fuzz tests the encryption of arbitrary data with the
|
||||
// initiator.
|
||||
func FuzzStaticInitEncrypt(f *testing.F) {
|
||||
f.Fuzz(func(t *testing.T, data []byte) {
|
||||
// Ensure that length of message is not greater than max allowed
|
||||
// size.
|
||||
@ -606,9 +606,9 @@ func Fuzz_static_init_encrypt(f *testing.F) {
|
||||
})
|
||||
}
|
||||
|
||||
// Fuzz_static_resp_decrypt fuzz tests the decryption of arbitrary data with
|
||||
// the responder.
|
||||
func Fuzz_static_resp_decrypt(f *testing.F) {
|
||||
// FuzzStaticRespDecrypt fuzz tests the decryption of arbitrary data with the
|
||||
// responder.
|
||||
func FuzzStaticRespDecrypt(f *testing.F) {
|
||||
f.Fuzz(func(t *testing.T, data []byte) {
|
||||
// This will return brontide machines with static keys.
|
||||
initiator, responder := getStaticBrontideMachines()
|
||||
@ -627,9 +627,9 @@ func Fuzz_static_resp_decrypt(f *testing.F) {
|
||||
})
|
||||
}
|
||||
|
||||
// Fuzz_static_resp_enc_dec fuzz tests the round-trip encryption and decryption
|
||||
// FuzzStaticRespEncDec fuzz tests the round-trip encryption and decryption
|
||||
// between the responder and the initiator.
|
||||
func Fuzz_static_resp_enc_dec(f *testing.F) {
|
||||
func FuzzStaticRespEncDec(f *testing.F) {
|
||||
f.Fuzz(func(t *testing.T, data []byte) {
|
||||
// Ensure that length of message is not greater than max allowed
|
||||
// size.
|
||||
@ -670,9 +670,9 @@ func Fuzz_static_resp_enc_dec(f *testing.F) {
|
||||
})
|
||||
}
|
||||
|
||||
// Fuzz_static_resp_encrypt fuzz tests the encryption of arbitrary data with
|
||||
// the responder.
|
||||
func Fuzz_static_resp_encrypt(f *testing.F) {
|
||||
// FuzzStaticRespEncrypt fuzz tests the encryption of arbitrary data with the
|
||||
// responder.
|
||||
func FuzzStaticRespEncrypt(f *testing.F) {
|
||||
f.Fuzz(func(t *testing.T, data []byte) {
|
||||
// Ensure that length of message is not greater than max allowed
|
||||
// size.
|
||||
|
@ -59,7 +59,7 @@ func harness(t *testing.T, data []byte) {
|
||||
}
|
||||
}
|
||||
|
||||
func Fuzz_accept_channel(f *testing.F) {
|
||||
func FuzzAcceptChannel(f *testing.F) {
|
||||
f.Fuzz(func(t *testing.T, data []byte) {
|
||||
data = prefixWithMsgType(data, MsgAcceptChannel)
|
||||
// Create a reader with the byte array.
|
||||
@ -168,7 +168,7 @@ func Fuzz_accept_channel(f *testing.F) {
|
||||
})
|
||||
}
|
||||
|
||||
func Fuzz_announce_signatures(f *testing.F) {
|
||||
func FuzzAnnounceSignatures(f *testing.F) {
|
||||
f.Fuzz(func(t *testing.T, data []byte) {
|
||||
// Prefix with MsgAnnounceSignatures.
|
||||
data = prefixWithMsgType(data, MsgAnnounceSignatures)
|
||||
@ -179,7 +179,7 @@ func Fuzz_announce_signatures(f *testing.F) {
|
||||
})
|
||||
}
|
||||
|
||||
func Fuzz_channel_announcement(f *testing.F) {
|
||||
func FuzzChannelAnnouncement(f *testing.F) {
|
||||
f.Fuzz(func(t *testing.T, data []byte) {
|
||||
// Prefix with MsgChannelAnnouncement.
|
||||
data = prefixWithMsgType(data, MsgChannelAnnouncement)
|
||||
@ -190,7 +190,7 @@ func Fuzz_channel_announcement(f *testing.F) {
|
||||
})
|
||||
}
|
||||
|
||||
func Fuzz_channel_reestablish(f *testing.F) {
|
||||
func FuzzChannelReestablish(f *testing.F) {
|
||||
f.Fuzz(func(t *testing.T, data []byte) {
|
||||
// Prefix with MsgChannelReestablish.
|
||||
data = prefixWithMsgType(data, MsgChannelReestablish)
|
||||
@ -201,7 +201,7 @@ func Fuzz_channel_reestablish(f *testing.F) {
|
||||
})
|
||||
}
|
||||
|
||||
func Fuzz_channel_update(f *testing.F) {
|
||||
func FuzzChannelUpdate(f *testing.F) {
|
||||
f.Fuzz(func(t *testing.T, data []byte) {
|
||||
// Prefix with MsgChannelUpdate.
|
||||
data = prefixWithMsgType(data, MsgChannelUpdate)
|
||||
@ -212,7 +212,7 @@ func Fuzz_channel_update(f *testing.F) {
|
||||
})
|
||||
}
|
||||
|
||||
func Fuzz_closing_signed(f *testing.F) {
|
||||
func FuzzClosingSigned(f *testing.F) {
|
||||
f.Fuzz(func(t *testing.T, data []byte) {
|
||||
// Prefix with MsgClosingSigned.
|
||||
data = prefixWithMsgType(data, MsgClosingSigned)
|
||||
@ -223,7 +223,7 @@ func Fuzz_closing_signed(f *testing.F) {
|
||||
})
|
||||
}
|
||||
|
||||
func Fuzz_commit_sig(f *testing.F) {
|
||||
func FuzzCommitSig(f *testing.F) {
|
||||
f.Fuzz(func(t *testing.T, data []byte) {
|
||||
// Prefix with MsgCommitSig.
|
||||
data = prefixWithMsgType(data, MsgCommitSig)
|
||||
@ -234,7 +234,7 @@ func Fuzz_commit_sig(f *testing.F) {
|
||||
})
|
||||
}
|
||||
|
||||
func Fuzz_error(f *testing.F) {
|
||||
func FuzzError(f *testing.F) {
|
||||
f.Fuzz(func(t *testing.T, data []byte) {
|
||||
// Prefix with MsgError.
|
||||
data = prefixWithMsgType(data, MsgError)
|
||||
@ -245,7 +245,7 @@ func Fuzz_error(f *testing.F) {
|
||||
})
|
||||
}
|
||||
|
||||
func Fuzz_funding_created(f *testing.F) {
|
||||
func FuzzFundingCreated(f *testing.F) {
|
||||
f.Fuzz(func(t *testing.T, data []byte) {
|
||||
// Prefix with MsgFundingCreated.
|
||||
data = prefixWithMsgType(data, MsgFundingCreated)
|
||||
@ -256,7 +256,7 @@ func Fuzz_funding_created(f *testing.F) {
|
||||
})
|
||||
}
|
||||
|
||||
func Fuzz_funding_locked(f *testing.F) {
|
||||
func FuzzFundingLocked(f *testing.F) {
|
||||
f.Fuzz(func(t *testing.T, data []byte) {
|
||||
// Prefix with MsgFundingLocked.
|
||||
data = prefixWithMsgType(data, MsgFundingLocked)
|
||||
@ -267,7 +267,7 @@ func Fuzz_funding_locked(f *testing.F) {
|
||||
})
|
||||
}
|
||||
|
||||
func Fuzz_funding_signed(f *testing.F) {
|
||||
func FuzzFundingSigned(f *testing.F) {
|
||||
f.Fuzz(func(t *testing.T, data []byte) {
|
||||
// Prefix with MsgFundingSigned.
|
||||
data = prefixWithMsgType(data, MsgFundingSigned)
|
||||
@ -278,7 +278,7 @@ func Fuzz_funding_signed(f *testing.F) {
|
||||
})
|
||||
}
|
||||
|
||||
func Fuzz_gossip_timestamp_range(f *testing.F) {
|
||||
func FuzzGossipTimestampRange(f *testing.F) {
|
||||
f.Fuzz(func(t *testing.T, data []byte) {
|
||||
// Prefix with MsgGossipTimestampRange.
|
||||
data = prefixWithMsgType(data, MsgGossipTimestampRange)
|
||||
@ -289,7 +289,7 @@ func Fuzz_gossip_timestamp_range(f *testing.F) {
|
||||
})
|
||||
}
|
||||
|
||||
func Fuzz_init(f *testing.F) {
|
||||
func FuzzInit(f *testing.F) {
|
||||
f.Fuzz(func(t *testing.T, data []byte) {
|
||||
// Prefix with MsgInit.
|
||||
data = prefixWithMsgType(data, MsgInit)
|
||||
@ -300,7 +300,7 @@ func Fuzz_init(f *testing.F) {
|
||||
})
|
||||
}
|
||||
|
||||
func Fuzz_node_announcement(f *testing.F) {
|
||||
func FuzzNodeAnnouncement(f *testing.F) {
|
||||
f.Fuzz(func(t *testing.T, data []byte) {
|
||||
// Prefix with MsgNodeAnnouncement.
|
||||
data = prefixWithMsgType(data, MsgNodeAnnouncement)
|
||||
@ -391,7 +391,7 @@ func Fuzz_node_announcement(f *testing.F) {
|
||||
})
|
||||
}
|
||||
|
||||
func Fuzz_open_channel(f *testing.F) {
|
||||
func FuzzOpenChannel(f *testing.F) {
|
||||
f.Fuzz(func(t *testing.T, data []byte) {
|
||||
// Prefix with MsgOpenChannel.
|
||||
data = prefixWithMsgType(data, MsgOpenChannel)
|
||||
@ -524,7 +524,7 @@ func Fuzz_open_channel(f *testing.F) {
|
||||
})
|
||||
}
|
||||
|
||||
func Fuzz_ping(f *testing.F) {
|
||||
func FuzzPing(f *testing.F) {
|
||||
f.Fuzz(func(t *testing.T, data []byte) {
|
||||
// Prefix with MsgPing.
|
||||
data = prefixWithMsgType(data, MsgPing)
|
||||
@ -535,7 +535,7 @@ func Fuzz_ping(f *testing.F) {
|
||||
})
|
||||
}
|
||||
|
||||
func Fuzz_pong(f *testing.F) {
|
||||
func FuzzPong(f *testing.F) {
|
||||
f.Fuzz(func(t *testing.T, data []byte) {
|
||||
// Prefix with MsgPong.
|
||||
data = prefixWithMsgType(data, MsgPong)
|
||||
@ -546,7 +546,7 @@ func Fuzz_pong(f *testing.F) {
|
||||
})
|
||||
}
|
||||
|
||||
func Fuzz_query_channel_range(f *testing.F) {
|
||||
func FuzzQueryChannelRange(f *testing.F) {
|
||||
f.Fuzz(func(t *testing.T, data []byte) {
|
||||
// Prefix with MsgQueryChannelRange.
|
||||
data = prefixWithMsgType(data, MsgQueryChannelRange)
|
||||
@ -557,7 +557,7 @@ func Fuzz_query_channel_range(f *testing.F) {
|
||||
})
|
||||
}
|
||||
|
||||
func Fuzz_zlib_query_short_chan_ids(f *testing.F) {
|
||||
func FuzzZlibQueryShortChanIDs(f *testing.F) {
|
||||
f.Fuzz(func(t *testing.T, data []byte) {
|
||||
var buf bytes.Buffer
|
||||
zlibWriter := zlib.NewWriter(&buf)
|
||||
@ -595,7 +595,7 @@ func Fuzz_zlib_query_short_chan_ids(f *testing.F) {
|
||||
})
|
||||
}
|
||||
|
||||
func Fuzz_query_short_chan_ids(f *testing.F) {
|
||||
func FuzzQueryShortChanIDs(f *testing.F) {
|
||||
f.Fuzz(func(t *testing.T, data []byte) {
|
||||
// Prefix with MsgQueryShortChanIDs.
|
||||
data = prefixWithMsgType(data, MsgQueryShortChanIDs)
|
||||
@ -606,7 +606,7 @@ func Fuzz_query_short_chan_ids(f *testing.F) {
|
||||
})
|
||||
}
|
||||
|
||||
func Fuzz_zlib_reply_channel_range(f *testing.F) {
|
||||
func FuzzZlibReplyChannelRange(f *testing.F) {
|
||||
f.Fuzz(func(t *testing.T, data []byte) {
|
||||
var buf bytes.Buffer
|
||||
zlibWriter := zlib.NewWriter(&buf)
|
||||
@ -652,7 +652,7 @@ func Fuzz_zlib_reply_channel_range(f *testing.F) {
|
||||
})
|
||||
}
|
||||
|
||||
func Fuzz_reply_channel_range(f *testing.F) {
|
||||
func FuzzReplyChannelRange(f *testing.F) {
|
||||
f.Fuzz(func(t *testing.T, data []byte) {
|
||||
// Prefix with MsgReplyChannelRange.
|
||||
data = prefixWithMsgType(data, MsgReplyChannelRange)
|
||||
@ -663,7 +663,7 @@ func Fuzz_reply_channel_range(f *testing.F) {
|
||||
})
|
||||
}
|
||||
|
||||
func Fuzz_reply_short_chan_ids_end(f *testing.F) {
|
||||
func FuzzReplyShortChanIDsEnd(f *testing.F) {
|
||||
f.Fuzz(func(t *testing.T, data []byte) {
|
||||
// Prefix with MsgReplyShortChanIDsEnd.
|
||||
data = prefixWithMsgType(data, MsgReplyShortChanIDsEnd)
|
||||
@ -674,7 +674,7 @@ func Fuzz_reply_short_chan_ids_end(f *testing.F) {
|
||||
})
|
||||
}
|
||||
|
||||
func Fuzz_revoke_and_ack(f *testing.F) {
|
||||
func FuzzRevokeAndAck(f *testing.F) {
|
||||
f.Fuzz(func(t *testing.T, data []byte) {
|
||||
// Prefix with MsgRevokeAndAck.
|
||||
data = prefixWithMsgType(data, MsgRevokeAndAck)
|
||||
@ -685,7 +685,7 @@ func Fuzz_revoke_and_ack(f *testing.F) {
|
||||
})
|
||||
}
|
||||
|
||||
func Fuzz_shutdown(f *testing.F) {
|
||||
func FuzzShutdown(f *testing.F) {
|
||||
f.Fuzz(func(t *testing.T, data []byte) {
|
||||
// Prefix with MsgShutdown.
|
||||
data = prefixWithMsgType(data, MsgShutdown)
|
||||
@ -696,7 +696,7 @@ func Fuzz_shutdown(f *testing.F) {
|
||||
})
|
||||
}
|
||||
|
||||
func Fuzz_update_add_htlc(f *testing.F) {
|
||||
func FuzzUpdateAddHTLC(f *testing.F) {
|
||||
f.Fuzz(func(t *testing.T, data []byte) {
|
||||
// Prefix with MsgUpdateAddHTLC.
|
||||
data = prefixWithMsgType(data, MsgUpdateAddHTLC)
|
||||
@ -707,7 +707,7 @@ func Fuzz_update_add_htlc(f *testing.F) {
|
||||
})
|
||||
}
|
||||
|
||||
func Fuzz_update_fail_htlc(f *testing.F) {
|
||||
func FuzzUpdateFailHTLC(f *testing.F) {
|
||||
f.Fuzz(func(t *testing.T, data []byte) {
|
||||
// Prefix with MsgUpdateFailHTLC.
|
||||
data = prefixWithMsgType(data, MsgUpdateFailHTLC)
|
||||
@ -718,7 +718,7 @@ func Fuzz_update_fail_htlc(f *testing.F) {
|
||||
})
|
||||
}
|
||||
|
||||
func Fuzz_update_fail_malformed_htlc(f *testing.F) {
|
||||
func FuzzUpdateFailMalformedHTLC(f *testing.F) {
|
||||
f.Fuzz(func(t *testing.T, data []byte) {
|
||||
// Prefix with MsgUpdateFailMalformedHTLC.
|
||||
data = prefixWithMsgType(data, MsgUpdateFailMalformedHTLC)
|
||||
@ -729,7 +729,7 @@ func Fuzz_update_fail_malformed_htlc(f *testing.F) {
|
||||
})
|
||||
}
|
||||
|
||||
func Fuzz_update_fee(f *testing.F) {
|
||||
func FuzzUpdateFee(f *testing.F) {
|
||||
f.Fuzz(func(t *testing.T, data []byte) {
|
||||
// Prefix with MsgUpdateFee.
|
||||
data = prefixWithMsgType(data, MsgUpdateFee)
|
||||
@ -740,7 +740,7 @@ func Fuzz_update_fee(f *testing.F) {
|
||||
})
|
||||
}
|
||||
|
||||
func Fuzz_update_fulfill_htlc(f *testing.F) {
|
||||
func FuzzUpdateFulfillHTLC(f *testing.F) {
|
||||
f.Fuzz(func(t *testing.T, data []byte) {
|
||||
// Prefix with MsgUpdateFulFillHTLC.
|
||||
data = prefixWithMsgType(data, MsgUpdateFulfillHTLC)
|
||||
|
@ -62,7 +62,7 @@ func harness(t *testing.T, data []byte, emptyMsg Message) {
|
||||
}
|
||||
}
|
||||
|
||||
func Fuzz_create_session_reply(f *testing.F) {
|
||||
func FuzzCreateSessionReply(f *testing.F) {
|
||||
f.Fuzz(func(t *testing.T, data []byte) {
|
||||
// Prefix with MsgCreateSessionReply.
|
||||
data = prefixWithMsgType(data, MsgCreateSessionReply)
|
||||
@ -77,7 +77,7 @@ func Fuzz_create_session_reply(f *testing.F) {
|
||||
})
|
||||
}
|
||||
|
||||
func Fuzz_create_session(f *testing.F) {
|
||||
func FuzzCreateSession(f *testing.F) {
|
||||
f.Fuzz(func(t *testing.T, data []byte) {
|
||||
// Prefix with MsgCreateSession.
|
||||
data = prefixWithMsgType(data, MsgCreateSession)
|
||||
@ -92,7 +92,7 @@ func Fuzz_create_session(f *testing.F) {
|
||||
})
|
||||
}
|
||||
|
||||
func Fuzz_delete_session_reply(f *testing.F) {
|
||||
func FuzzDeleteSessionReply(f *testing.F) {
|
||||
f.Fuzz(func(t *testing.T, data []byte) {
|
||||
// Prefix with MsgDeleteSessionReply.
|
||||
data = prefixWithMsgType(data, MsgDeleteSessionReply)
|
||||
@ -107,7 +107,7 @@ func Fuzz_delete_session_reply(f *testing.F) {
|
||||
})
|
||||
}
|
||||
|
||||
func Fuzz_delete_session(f *testing.F) {
|
||||
func FuzzDeleteSession(f *testing.F) {
|
||||
f.Fuzz(func(t *testing.T, data []byte) {
|
||||
// Prefix with MsgDeleteSession.
|
||||
data = prefixWithMsgType(data, MsgDeleteSession)
|
||||
@ -122,7 +122,7 @@ func Fuzz_delete_session(f *testing.F) {
|
||||
})
|
||||
}
|
||||
|
||||
func Fuzz_error(f *testing.F) {
|
||||
func FuzzError(f *testing.F) {
|
||||
f.Fuzz(func(t *testing.T, data []byte) {
|
||||
// Prefix with MsgError.
|
||||
data = prefixWithMsgType(data, MsgError)
|
||||
@ -137,7 +137,7 @@ func Fuzz_error(f *testing.F) {
|
||||
})
|
||||
}
|
||||
|
||||
func Fuzz_init(f *testing.F) {
|
||||
func FuzzInit(f *testing.F) {
|
||||
f.Fuzz(func(t *testing.T, data []byte) {
|
||||
// Prefix with MsgInit.
|
||||
data = prefixWithMsgType(data, MsgInit)
|
||||
@ -152,7 +152,7 @@ func Fuzz_init(f *testing.F) {
|
||||
})
|
||||
}
|
||||
|
||||
func Fuzz_state_update_reply(f *testing.F) {
|
||||
func FuzzStateUpdateReply(f *testing.F) {
|
||||
f.Fuzz(func(t *testing.T, data []byte) {
|
||||
// Prefix with MsgStateUpdateReply.
|
||||
data = prefixWithMsgType(data, MsgStateUpdateReply)
|
||||
@ -167,7 +167,7 @@ func Fuzz_state_update_reply(f *testing.F) {
|
||||
})
|
||||
}
|
||||
|
||||
func Fuzz_state_update(f *testing.F) {
|
||||
func FuzzStateUpdate(f *testing.F) {
|
||||
f.Fuzz(func(t *testing.T, data []byte) {
|
||||
// Prefix with MsgStateUpdate.
|
||||
data = prefixWithMsgType(data, MsgStateUpdate)
|
||||
|
@ -11,7 +11,7 @@ import (
|
||||
"github.com/btcsuite/btcd/chaincfg/chainhash"
|
||||
)
|
||||
|
||||
func Fuzz_decode(f *testing.F) {
|
||||
func FuzzDecode(f *testing.F) {
|
||||
f.Fuzz(func(t *testing.T, data string) {
|
||||
inv, err := Decode(data, &chaincfg.TestNet3Params)
|
||||
if err != nil {
|
||||
@ -25,7 +25,7 @@ func Fuzz_decode(f *testing.F) {
|
||||
})
|
||||
}
|
||||
|
||||
func Fuzz_encode(f *testing.F) {
|
||||
func FuzzEncode(f *testing.F) {
|
||||
f.Fuzz(func(t *testing.T, data string) {
|
||||
inv, err := Decode(data, &chaincfg.TestNet3Params)
|
||||
if err != nil {
|
||||
|
Loading…
x
Reference in New Issue
Block a user