Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func FromTimeStamp ¶
func HumanToBlockchain ¶
func HumanToBlockchain(amount string, decimals int) xc.AmountBlockchain
func Reserialize ¶
func Reserialize[T any](val *T) *T
reserialize will drop internal fields set by constructors
Types ¶
type MockHTTPServer ¶
type MockHTTPServer struct { *httptest.Server Counter int Response interface{} StatusCodes []int // contains filtered or unexported fields }
MockHTTPServer is a mocked HTTP server
type MockJSONRPCServer ¶
type MockJSONRPCServer struct { *httptest.Server Counter int Response interface{} // contains filtered or unexported fields }
MockJSONRPCServer is a mocked RPC server
func MockJSONRPC ¶
func MockJSONRPC(t *testing.T, response interface{}) (mock *MockJSONRPCServer, close func())
MockJSONRPC creates a new MockJSONRPCServer given a response, or array of responses
type MockXcTx ¶
type MockXcTx struct { SerializedSignedTx []byte Signatures []xc.TxSignature }
An object that only supports .Serialize for SubmitTx()
func (*MockXcTx) AddSignatures ¶
func (tx *MockXcTx) AddSignatures(...xc.TxSignature) error
func (*MockXcTx) GetSignatures ¶
func (tx *MockXcTx) GetSignatures() []xc.TxSignature
Click to show internal directories.
Click to hide internal directories.