Struct concordium_std::test_infrastructure::TestChainMeta
source · pub struct TestChainMeta { /* private fields */ }👎Deprecated since 8.1.0: Deprecated in favor of concordium-smart-contract-testing.
Expand description
Placeholder for the context chain meta data.
All the fields are optionally set and the getting an unset field will result
in test failing.
For most cases it is used as part of either
TestInitContext or
TestReceiveContext.
Use only in unit tests!
Defaults to having all of the fields unset
Implementations§
source§impl TestChainMeta
impl TestChainMeta
sourcepub fn empty() -> Self
👎Deprecated since 8.1.0: Deprecated in favor of concordium-smart-contract-testing.
pub fn empty() -> Self
Create an TestChainMeta where every field is unset, and getting any of
the fields will result in fail!.
sourcepub fn set_slot_time(&mut self, value: SlotTime) -> &mut Self
👎Deprecated since 8.1.0: Deprecated in favor of concordium-smart-contract-testing.
pub fn set_slot_time(&mut self, value: SlotTime) -> &mut Self
Set the block slot time
Trait Implementations§
source§impl Clone for TestChainMeta
impl Clone for TestChainMeta
source§fn clone(&self) -> TestChainMeta
fn clone(&self) -> TestChainMeta
Returns a copy of the value. Read more
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moresource§impl Default for TestChainMeta
impl Default for TestChainMeta
source§fn default() -> TestChainMeta
fn default() -> TestChainMeta
Returns the “default value” for a type. Read more
source§impl HasChainMetadata for TestChainMeta
impl HasChainMetadata for TestChainMeta
Auto Trait Implementations§
impl RefUnwindSafe for TestChainMeta
impl Send for TestChainMeta
impl Sync for TestChainMeta
impl Unpin for TestChainMeta
impl UnwindSafe for TestChainMeta
Blanket Implementations§
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more