diff --git a/btcjson/dagsvrcmds.go b/btcjson/dagsvrcmds.go index 4a3555a4a..561634bb2 100644 --- a/btcjson/dagsvrcmds.go +++ b/btcjson/dagsvrcmds.go @@ -539,24 +539,6 @@ func NewGetTxOutCmd(txHash string, vout uint32, includeMempool *bool) *GetTxOutC } } -// GetTxOutProofCmd defines the getTxOutProof JSON-RPC command. -type GetTxOutProofCmd struct { - TxIDs []string - BlockHash *string -} - -// NewGetTxOutProofCmd returns a new instance which can be used to issue a -// getTxOutProof JSON-RPC command. -// -// The parameters which are pointers indicate they are optional. Passing nil -// for optional parameters will use the default value. -func NewGetTxOutProofCmd(txIDs []string, blockHash *string) *GetTxOutProofCmd { - return &GetTxOutProofCmd{ - TxIDs: txIDs, - BlockHash: blockHash, - } -} - // GetTxOutSetInfoCmd defines the getTxOutSetInfo JSON-RPC command. type GetTxOutSetInfoCmd struct{} @@ -766,19 +748,6 @@ func NewVerifyMessageCmd(address, signature, message string) *VerifyMessageCmd { } } -// VerifyTxOutProofCmd defines the verifyTxOutProof JSON-RPC command. -type VerifyTxOutProofCmd struct { - Proof string -} - -// NewVerifyTxOutProofCmd returns a new instance which can be used to issue a -// verifyTxOutProof JSON-RPC command. -func NewVerifyTxOutProofCmd(proof string) *VerifyTxOutProofCmd { - return &VerifyTxOutProofCmd{ - Proof: proof, - } -} - func init() { // No special flags for commands in this file. flags := UsageFlag(0) @@ -816,7 +785,6 @@ func init() { MustRegisterCmd("getRawTransaction", (*GetRawTransactionCmd)(nil), flags) MustRegisterCmd("getSubnetwork", (*GetSubnetworkCmd)(nil), flags) MustRegisterCmd("getTxOut", (*GetTxOutCmd)(nil), flags) - MustRegisterCmd("getTxOutProof", (*GetTxOutProofCmd)(nil), flags) MustRegisterCmd("getTxOutSetInfo", (*GetTxOutSetInfoCmd)(nil), flags) MustRegisterCmd("help", (*HelpCmd)(nil), flags) MustRegisterCmd("invalidateBlock", (*InvalidateBlockCmd)(nil), flags) @@ -832,5 +800,4 @@ func init() { MustRegisterCmd("uptime", (*UptimeCmd)(nil), flags) MustRegisterCmd("validateAddress", (*ValidateAddressCmd)(nil), flags) MustRegisterCmd("verifyMessage", (*VerifyMessageCmd)(nil), flags) - MustRegisterCmd("verifyTxOutProof", (*VerifyTxOutProofCmd)(nil), flags) } diff --git a/btcjson/dagsvrcmds_test.go b/btcjson/dagsvrcmds_test.go index 0a55797ad..841bcdfac 100644 --- a/btcjson/dagsvrcmds_test.go +++ b/btcjson/dagsvrcmds_test.go @@ -657,36 +657,6 @@ func TestDAGSvrCmds(t *testing.T) { IncludeMempool: btcjson.Bool(true), }, }, - { - name: "getTxOutProof", - newCmd: func() (interface{}, error) { - return btcjson.NewCmd("getTxOutProof", []string{"123", "456"}) - }, - staticCmd: func() interface{} { - return btcjson.NewGetTxOutProofCmd([]string{"123", "456"}, nil) - }, - marshalled: `{"jsonrpc":"1.0","method":"getTxOutProof","params":[["123","456"]],"id":1}`, - unmarshalled: &btcjson.GetTxOutProofCmd{ - TxIDs: []string{"123", "456"}, - }, - }, - { - name: "getTxOutProof optional", - newCmd: func() (interface{}, error) { - return btcjson.NewCmd("getTxOutProof", []string{"123", "456"}, - btcjson.String("000000000000034a7dedef4a161fa058a2d67a173a90155f3a2fe6fc132e0ebf")) - }, - staticCmd: func() interface{} { - return btcjson.NewGetTxOutProofCmd([]string{"123", "456"}, - btcjson.String("000000000000034a7dedef4a161fa058a2d67a173a90155f3a2fe6fc132e0ebf")) - }, - marshalled: `{"jsonrpc":"1.0","method":"getTxOutProof","params":[["123","456"],` + - `"000000000000034a7dedef4a161fa058a2d67a173a90155f3a2fe6fc132e0ebf"],"id":1}`, - unmarshalled: &btcjson.GetTxOutProofCmd{ - TxIDs: []string{"123", "456"}, - BlockHash: btcjson.String("000000000000034a7dedef4a161fa058a2d67a173a90155f3a2fe6fc132e0ebf"), - }, - }, { name: "getTxOutSetInfo", newCmd: func() (interface{}, error) { @@ -1063,19 +1033,6 @@ func TestDAGSvrCmds(t *testing.T) { Message: "test", }, }, - { - name: "verifyTxOutProof", - newCmd: func() (interface{}, error) { - return btcjson.NewCmd("verifyTxOutProof", "test") - }, - staticCmd: func() interface{} { - return btcjson.NewVerifyTxOutProofCmd("test") - }, - marshalled: `{"jsonrpc":"1.0","method":"verifyTxOutProof","params":["test"],"id":1}`, - unmarshalled: &btcjson.VerifyTxOutProofCmd{ - Proof: "test", - }, - }, } t.Logf("Running %d tests", len(tests))