ibc_testkit::fixtures::core::context

Struct DummyStoreGenericTestContextBuilder

source
pub struct DummyStoreGenericTestContextBuilder<S, H, ___State = __DummyStoreGenericTestContextBuilderInitialState>{ /* private fields */ }
Expand description

Use builder syntax to set the required parameters and finish by calling the method Self::call().

Implementations§

source§

impl<S, H, __Host, __BlockTime, __LatestTimestamp, __BlockParamsHistory, __LatestHeight> DummyStoreGenericTestContextBuilder<S, H, (__Host, __BlockTime, __LatestTimestamp, __BlockParamsHistory, __LatestHeight)>

source

pub fn call(self) -> StoreGenericTestContext<S, H>
where __Host: IntoSet<Option<H>, DummyStoreGenericTestContextBuilder__host>, __BlockTime: IntoSet<Option<Duration>, DummyStoreGenericTestContextBuilder__block_time>, __LatestTimestamp: IntoSet<Option<Timestamp>, DummyStoreGenericTestContextBuilder__latest_timestamp>, __BlockParamsHistory: IntoSet<Option<Vec<H::BlockParams>>, DummyStoreGenericTestContextBuilder__block_params_history>, __LatestHeight: IntoSet<Option<Height>, DummyStoreGenericTestContextBuilder__latest_height>,

Finishes building and performs the requested action.

source

pub fn maybe_host( self, value: Option<H>, ) -> <Self as __DummyStoreGenericTestContextBuilderSetMember>::Host
where __Host: IsUnset,

Same as Self::host, but accepts an Option as input. See that method’s documentation for more details.

source

pub fn host( self, value: H, ) -> <Self as __DummyStoreGenericTestContextBuilderSetMember>::Host
where __Host: IsUnset,

Sets the value of host. See dummy_store_generic_test_context() for more info.

source

pub fn maybe_block_time( self, value: Option<Duration>, ) -> <Self as __DummyStoreGenericTestContextBuilderSetMember>::BlockTime
where __BlockTime: IsUnset,

Same as Self::block_time, but accepts an Option as input. See that method’s documentation for more details.

source

pub fn block_time( self, value: Duration, ) -> <Self as __DummyStoreGenericTestContextBuilderSetMember>::BlockTime
where __BlockTime: IsUnset,

Sets the value of block_time. See dummy_store_generic_test_context() for more info.

source

pub fn maybe_latest_timestamp( self, value: Option<Timestamp>, ) -> <Self as __DummyStoreGenericTestContextBuilderSetMember>::LatestTimestamp
where __LatestTimestamp: IsUnset,

Same as Self::latest_timestamp, but accepts an Option as input. See that method’s documentation for more details.

source

pub fn latest_timestamp( self, value: Timestamp, ) -> <Self as __DummyStoreGenericTestContextBuilderSetMember>::LatestTimestamp
where __LatestTimestamp: IsUnset,

Sets the value of latest_timestamp. See dummy_store_generic_test_context() for more info.

source

pub fn maybe_block_params_history( self, value: Option<Vec<H::BlockParams>>, ) -> <Self as __DummyStoreGenericTestContextBuilderSetMember>::BlockParamsHistory
where __BlockParamsHistory: IsUnset,

Same as Self::block_params_history, but accepts an Option as input. See that method’s documentation for more details.

source

pub fn block_params_history( self, value: Vec<H::BlockParams>, ) -> <Self as __DummyStoreGenericTestContextBuilderSetMember>::BlockParamsHistory
where __BlockParamsHistory: IsUnset,

Sets the value of block_params_history. See dummy_store_generic_test_context() for more info.

source

pub fn maybe_latest_height( self, value: Option<Height>, ) -> <Self as __DummyStoreGenericTestContextBuilderSetMember>::LatestHeight
where __LatestHeight: IsUnset,

Same as Self::latest_height, but accepts an Option as input. See that method’s documentation for more details.

source

pub fn latest_height( self, value: Height, ) -> <Self as __DummyStoreGenericTestContextBuilderSetMember>::LatestHeight
where __LatestHeight: IsUnset,

Sets the value of latest_height. See dummy_store_generic_test_context() for more info.

Auto Trait Implementations§

§

impl<S, H, ___State> Freeze for DummyStoreGenericTestContextBuilder<S, H, ___State>
where <H as TestHost>::ClientState: Sized, ___State: Freeze,

§

impl<S, H, ___State> RefUnwindSafe for DummyStoreGenericTestContextBuilder<S, H, ___State>

§

impl<S, H, ___State> Send for DummyStoreGenericTestContextBuilder<S, H, ___State>
where <H as TestHost>::ClientState: Sized, ___State: Send, H: Send, <H as TestHost>::BlockParams: Send,

§

impl<S, H, ___State> Sync for DummyStoreGenericTestContextBuilder<S, H, ___State>
where <H as TestHost>::ClientState: Sized, ___State: Sync, H: Sync, <H as TestHost>::BlockParams: Sync,

§

impl<S, H, ___State> Unpin for DummyStoreGenericTestContextBuilder<S, H, ___State>
where <H as TestHost>::ClientState: Sized, ___State: Unpin, H: Unpin, S: Unpin, <H as TestHost>::BlockParams: Unpin,

§

impl<S, H, ___State> UnwindSafe for DummyStoreGenericTestContextBuilder<S, H, ___State>

Blanket Implementations§

source§

impl<T> Any for T
where T: 'static + ?Sized,

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
source§

impl<T> Borrow<T> for T
where T: ?Sized,

source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
source§

impl<T> From<T> for T

source§

fn from(t: T) -> T

Returns the argument unchanged.

source§

impl<T> Instrument for T

source§

fn instrument(self, span: Span) -> Instrumented<Self>

Instruments this type with the provided Span, returning an Instrumented wrapper. Read more
source§

fn in_current_span(self) -> Instrumented<Self>

Instruments this type with the current Span, returning an Instrumented wrapper. Read more
source§

impl<T, U> Into<U> for T
where U: From<T>,

source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

source§

impl<T> IntoRequest<T> for T

source§

fn into_request(self) -> Request<T>

Wrap the input message T in a tonic::Request
source§

impl<T, Raw> IntoResponse<Raw> for T
where T: Into<Raw>,

source§

impl<T> Same for T

source§

type Output = T

Should always be Self
source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

source§

type Error = Infallible

The type returned in the event of a conversion error.
source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.
source§

impl<V, T> VZip<V> for T
where V: MultiLane<T>,

source§

fn vzip(self) -> V

source§

impl<T> WithSubscriber for T

source§

fn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self>
where S: Into<Dispatch>,

Attaches the provided Subscriber to this type, returning a WithDispatch wrapper. Read more
source§

fn with_current_subscriber(self) -> WithDispatch<Self>

Attaches the current default Subscriber to this type, returning a WithDispatch wrapper. Read more
source§

impl<A> Async for A
where A: Send + Sync + 'static,

source§

impl<T, C> Convertible<C> for T
where T: TryFrom<C> + Into<C>,

source§

impl<T> JsonSchemaMaybe for T