[−][src]Struct sentry::test::TestTransport
Collects events instead of sending them.
Examples
use sentry::test::TestTransport; use sentry::{ClientOptions, Hub}; use std::sync::Arc; let transport = TestTransport::new(); let options = ClientOptions { dsn: Some("https://public@example.com/1".parse().unwrap()), transport: Some(Arc::new(transport.clone())), ..ClientOptions::default() }; Hub::current().bind_client(Some(Arc::new(options.into())));
Implementations
impl TestTransport
[src]
pub fn new() -> Arc<TestTransport>
[src]
Creates a new test transport.
pub fn fetch_and_clear_events(&self) -> Vec<Event<'static>>
[src]
Fetches and clears the contained events.
Trait Implementations
impl Transport for TestTransport
[src]
Auto Trait Implementations
impl RefUnwindSafe for TestTransport
impl Send for TestTransport
impl Sync for TestTransport
impl Unpin for TestTransport
impl UnwindSafe for TestTransport
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T> Same<T> for T
type Output = T
Should always be Self
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error
The type returned in the event of a conversion error.
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
[src]
impl<V, T> VZip<V> for T where
V: MultiLane<T>,
V: MultiLane<T>,