Documentation
¶
Index ¶
- Constants
- func DisplayMessage(msg []byte) int
- func MockDeps(funds []types.Coin) *std.Deps
- func MockEnv() types.Env
- func MockInfo(sender string, funds []types.Coin) types.MessageInfo
- type MockApi
- type MockIterator
- type MockQuerier
- func (q *MockQuerier) GetBalance(addr string) []types.Coin
- func (q *MockQuerier) HandleBank(request *types.BankQuery) (std.JSONType, error)
- func (q *MockQuerier) HandleQuery(request types.QueryRequest) (std.JSONType, error)
- func (q *MockQuerier) RawQuery(raw []byte) ([]byte, error)
- func (q *MockQuerier) SetBalance(addr string, balance []types.Coin)
- type MockStorage
Constants ¶
View Source
const MOCK_CONTRACT_ADDR = "test-contract"
Variables ¶
This section is empty.
Functions ¶
func DisplayMessage ¶
Types ¶
type MockApi ¶
type MockApi struct{}
func (MockApi) CanonicalAddress ¶
func (api MockApi) CanonicalAddress(human string) (types.CanonicalAddr, error)
func (MockApi) HumanAddress ¶
func (api MockApi) HumanAddress(canonical types.CanonicalAddr) (string, error)
func (MockApi) ValidateAddress ¶
type MockIterator ¶
func (MockIterator) Next ¶
func (iter MockIterator) Next() (key, value []byte, err error)
type MockQuerier ¶
func NewMockQuerier ¶
func NewMockQuerier(funds []types.Coin) *MockQuerier
func (*MockQuerier) GetBalance ¶
func (q *MockQuerier) GetBalance(addr string) []types.Coin
func (*MockQuerier) HandleBank ¶
func (*MockQuerier) HandleQuery ¶
func (q *MockQuerier) HandleQuery(request types.QueryRequest) (std.JSONType, error)
func (*MockQuerier) SetBalance ¶
func (q *MockQuerier) SetBalance(addr string, balance []types.Coin)
type MockStorage ¶
type MockStorage struct {
// contains filtered or unexported fields
}
func NewMockStorage ¶
func NewMockStorage() *MockStorage
func (*MockStorage) Remove ¶
func (s *MockStorage) Remove(key []byte) error
func (*MockStorage) Set ¶
func (s *MockStorage) Set(key, value []byte) error
Click to show internal directories.
Click to hide internal directories.