@@ -517,13 +517,13 @@ mod tests {
517
517
graphql_handler ( & schema, & context, req, payload) . await
518
518
}
519
519
520
- #[ actix_rt :: test]
520
+ #[ actix_web :: rt :: test]
521
521
async fn graphiql_response_does_not_panic ( ) {
522
522
let result = graphiql_handler ( "/abcd" , None ) . await ;
523
523
assert ! ( result. is_ok( ) )
524
524
}
525
525
526
- #[ actix_rt :: test]
526
+ #[ actix_web :: rt :: test]
527
527
async fn graphiql_endpoint_matches ( ) {
528
528
async fn graphql_handler ( ) -> Result < HttpResponse , Error > {
529
529
graphiql_handler ( "/abcd" , None ) . await
@@ -539,7 +539,7 @@ mod tests {
539
539
assert_eq ! ( resp. status( ) , http:: StatusCode :: OK ) ;
540
540
}
541
541
542
- #[ actix_rt :: test]
542
+ #[ actix_web :: rt :: test]
543
543
async fn graphiql_endpoint_returns_graphiql_source ( ) {
544
544
async fn graphql_handler ( ) -> Result < HttpResponse , Error > {
545
545
graphiql_handler ( "/dogs-api/graphql" , Some ( "/dogs-api/subscriptions" ) ) . await
@@ -564,7 +564,7 @@ mod tests {
564
564
) )
565
565
}
566
566
567
- #[ actix_rt :: test]
567
+ #[ actix_web :: rt :: test]
568
568
async fn playground_endpoint_matches ( ) {
569
569
async fn graphql_handler ( ) -> Result < HttpResponse , Error > {
570
570
playground_handler ( "/abcd" , None ) . await
@@ -580,7 +580,7 @@ mod tests {
580
580
assert_eq ! ( resp. status( ) , http:: StatusCode :: OK ) ;
581
581
}
582
582
583
- #[ actix_rt :: test]
583
+ #[ actix_web :: rt :: test]
584
584
async fn playground_endpoint_returns_playground_source ( ) {
585
585
async fn graphql_handler ( ) -> Result < HttpResponse , Error > {
586
586
playground_handler ( "/dogs-api/graphql" , Some ( "/dogs-api/subscriptions" ) ) . await
@@ -602,7 +602,7 @@ mod tests {
602
602
assert ! ( body. contains( "GraphQLPlayground.init(root, { endpoint: '/dogs-api/graphql', subscriptionEndpoint: '/dogs-api/subscriptions' })" ) ) ;
603
603
}
604
604
605
- #[ actix_rt :: test]
605
+ #[ actix_web :: rt :: test]
606
606
async fn graphql_post_works_json_post ( ) {
607
607
let schema: Schema = RootNode :: new (
608
608
Query ,
@@ -634,7 +634,7 @@ mod tests {
634
634
) ;
635
635
}
636
636
637
- #[ actix_rt :: test]
637
+ #[ actix_web :: rt :: test]
638
638
async fn graphql_get_works ( ) {
639
639
let schema: Schema = RootNode :: new (
640
640
Query ,
@@ -663,7 +663,7 @@ mod tests {
663
663
) ;
664
664
}
665
665
666
- #[ actix_rt :: test]
666
+ #[ actix_web :: rt :: test]
667
667
async fn batch_request_works ( ) {
668
668
use juniper:: {
669
669
tests:: fixtures:: starwars:: { model:: Database , schema:: Query } ,
@@ -715,7 +715,7 @@ mod tests {
715
715
716
716
impl TestActixWebIntegration {
717
717
fn make_request ( & self , req : test:: TestRequest ) -> TestResponse {
718
- actix_rt :: System :: new ( "request" ) . block_on ( async move {
718
+ actix_web :: rt :: System :: new ( "request" ) . block_on ( async move {
719
719
let schema = RootNode :: new (
720
720
Query ,
721
721
EmptyMutation :: < Database > :: new ( ) ,
@@ -877,7 +877,7 @@ mod subscription_tests {
877
877
subscriptions_handler ( req, stream, schema, config) . await
878
878
}
879
879
880
- #[ actix_rt :: test]
880
+ #[ actix_web :: rt :: test]
881
881
async fn test_actix_ws_integration ( ) {
882
882
run_ws_test_suite ( & mut TestActixWsIntegration :: default ( ) ) . await ;
883
883
}
0 commit comments