pub trait HttpIntegration {
    // Required methods
    fn get(&self, url: &str) -> TestResponse;
    fn post_json(&self, url: &str, body: &str) -> TestResponse;
    fn post_graphql(&self, url: &str, body: &str) -> TestResponse;
}
Expand description

Normalized way to make requests to the HTTP framework integration we are testing.

Required Methods§

source

fn get(&self, url: &str) -> TestResponse

Sends GET HTTP request to this integration with the provided url parameters string, and returns response returned by this integration.

source

fn post_json(&self, url: &str, body: &str) -> TestResponse

Sends POST HTTP request to this integration with the provided JSON-encoded body, and returns response returned by this integration.

source

fn post_graphql(&self, url: &str, body: &str) -> TestResponse

Sends POST HTTP request to this integration with the provided raw GraphQL query as body, and returns response returned by this integration.

Implementors§