Expand description
The drink crate provides a sandboxed runtime for testing smart contracts without a need for a running node.
Re-exports
Modules
- Module gathering common error and result types.
- Module containing the
Runtimetrait and its example implementations. You can usedrinkwith any runtime that implements theRuntimetrait. - A sandboxed runtime.
- This module provides a context-aware interface for interacting with contracts.
Macros
- A convenience macro that allows you to load a bundle found in the target directory of the current project.
Structs
- An opaque 32-byte cryptographic identifier.
- A struct representing the result of parsing a
.contractbundle file. - A contract mock.
Enums
- Reason why a dispatch call failed.
Constants
- Default gas limit.
Functions
- A helper function to create a message mock out of a typed closure.
Type Aliases
- Alias for
pallet-balances’s Balance type. - Main result type for the drink crate.
- Copied from pallet-contracts.
- An untyped message mock.
- Untyped result of a mocked call.
- Alias for
frame-system’sRuntimeCalltype. - Alias for a 4-byte selector.
Attribute Macros
- Defines a contract bundle provider.
- Defines a drink!-based test.