MCPcopy Create free account
hub / github.com/CPChain/chain / decodeTx

Function decodeTx

types/transaction_test.go:75–80  ·  view source on GitHub ↗
(data []byte)

Source from the content-addressed store, hash-verified

73}
74
75func decodeTx(data []byte) (*Transaction, error) {
76 var tx Transaction
77 t, err := &tx, rlp.Decode(bytes.NewReader(data), &tx)
78
79 return t, err
80}
81
82func defaultTestKey() (*ecdsa.PrivateKey, common.Address) {
83 key, _ := crypto.HexToECDSA("45a915e4d060149eb4365960e6a7a45f334393093061116b197e3240065ff2d8")

Callers 2

TestRecipientEmptyFunction · 0.85
TestRecipientNormalFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected