Eliminate tokio dependency in juniper_rocket_async (#920)

The `tokio` dependency is only required for tests and should
have been in the `dev-dependencies` section in `Cargo.toml`.

Since `rocket` already ships with a async test annotation
`tokio` can be removed completely.
This commit is contained in:
Filip Gospodinov 2021-04-19 19:54:21 +02:00 committed by GitHub
parent 9576c25fe7
commit 9dfd57198d
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 2 additions and 3 deletions

View file

@ -16,7 +16,6 @@ futures = "0.3.1"
juniper = { version = "0.15.4", path = "../juniper", default-features = false }
rocket = { git = "https://github.com/SergioBenitez/Rocket", branch = "master", default-features = false }
serde_json = "1.0.2"
tokio = { version = "1", features = ["macros", "rt"] }
[dev-dependencies]
juniper = { version = "0.15.4", path = "../juniper", features = ["expose-test-schema"] }

View file

@ -572,7 +572,7 @@ mod tests {
}
}
#[tokio::test]
#[rocket::async_test]
async fn test_rocket_integration() {
let rocket = make_rocket();
let client = Client::untracked(rocket).await.expect("valid rocket");
@ -581,7 +581,7 @@ mod tests {
http_tests::run_http_test_suite(&integration);
}
#[tokio::test]
#[rocket::async_test]
async fn test_operation_names() {
#[post("/", data = "<request>")]
fn post_graphql_assert_operation_name_handler(