[−][src]Struct shs::TestRequest
Test request for calling Server::test_request.
Implementations
impl TestRequest
[src]
pub fn new_with_body(s: &str, body: &[u8]) -> Result<TestRequest, Error>
[src]
Create a new test request with the method, URL, and body set.
The input string should be in the format "METHOD /path". The path will automatically be expanded to a full URL: "http://example.com/path".
pub fn new_with_json<S: Serialize>(
s: &str,
body: &S
) -> Result<TestRequest, Error>
[src]
s: &str,
body: &S
) -> Result<TestRequest, Error>
Create a new test request with the method, URL, and body set.
The input string should be in the format "METHOD /path". The path will automatically be expanded to a full URL: "http://example.com/path".
pub fn new(s: &str) -> Result<TestRequest, Error>
[src]
Create a new test request with the method and URL set.
The input string should be in the format "METHOD /path". The path will automatically be expanded to a full URL: "http://example.com/path".
Trait Implementations
impl Clone for TestRequest
[src]
fn clone(&self) -> TestRequest
[src]
fn clone_from(&mut self, source: &Self)
1.0.0[src]
impl Debug for TestRequest
[src]
impl Eq for TestRequest
[src]
impl PartialEq<TestRequest> for TestRequest
[src]
fn eq(&self, other: &TestRequest) -> bool
[src]
fn ne(&self, other: &TestRequest) -> bool
[src]
impl StructuralEq for TestRequest
[src]
impl StructuralPartialEq for TestRequest
[src]
Auto Trait Implementations
impl RefUnwindSafe for TestRequest
impl Send for TestRequest
impl Sync for TestRequest
impl Unpin for TestRequest
impl UnwindSafe for TestRequest
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> ToOwned for T where
T: Clone,
[src]
T: Clone,
type Owned = T
The resulting type after obtaining ownership.
fn to_owned(&self) -> T
[src]
fn clone_into(&self, target: &mut T)
[src]
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>,