Fmt juniper_actix crate

This commit is contained in:
tyranron 2020-09-02 22:52:15 +03:00
parent a684e1d91c
commit 0f400c3799
No known key found for this signature in database
GPG key ID: 762E144FB230A4F0

View file

@ -227,19 +227,22 @@ pub async fn playground_handler(
pub mod subscriptions {
use std::{fmt, sync::Arc};
use actix::prelude::*;
use actix::{Actor, StreamHandler};
use actix_web::http::header::{HeaderName, HeaderValue};
use actix_web::{web, HttpRequest, HttpResponse};
use actix::{prelude::*, Actor, StreamHandler};
use actix_web::{
http::header::{HeaderName, HeaderValue},
web, HttpRequest, HttpResponse,
};
use actix_web_actors::ws;
use tokio::sync::Mutex;
use juniper::futures::{
stream::{SplitSink, SplitStream, StreamExt},
SinkExt,
use juniper::{
futures::{
stream::{SplitSink, SplitStream, StreamExt},
SinkExt,
},
GraphQLSubscriptionType, GraphQLTypeAsync, RootNode, ScalarValue,
};
use juniper::{GraphQLSubscriptionType, GraphQLTypeAsync, RootNode, ScalarValue};
use juniper_graphql_ws::{ArcSchema, ClientMessage, Connection, Init, ServerMessage};
/// Serves the graphql-ws protocol over a WebSocket connection.
@ -782,7 +785,10 @@ mod subscription_tests {
use juniper::{
futures::{SinkExt, StreamExt},
http::tests::{run_ws_test_suite, WsIntegration, WsIntegrationMessage},
tests::fixtures::starwars::{model::Database, schema::Query, schema::Subscription},
tests::fixtures::starwars::{
model::Database,
schema::{Query, Subscription},
},
EmptyMutation, LocalBoxFuture,
};
use juniper_graphql_ws::ConnectionConfig;