File tree Expand file tree Collapse file tree 1 file changed +20
-1
lines changed Expand file tree Collapse file tree 1 file changed +20
-1
lines changed Original file line number Diff line number Diff line change @@ -132,7 +132,10 @@ struct Reply {
132132}
133133
134134type ChildFuture = Pin <
135- Box < dyn Future < Output = std:: result:: Result < std:: io:: Result < std:: process:: Output > , JoinError > > > ,
135+ Box <
136+ dyn Future < Output = std:: result:: Result < std:: io:: Result < std:: process:: Output > , JoinError > >
137+ + Send ,
138+ > ,
136139> ;
137140
138141/// Manage a child process proxy to fetch container images.
@@ -718,4 +721,20 @@ mod tests {
718721 Err ( e) => panic ! ( "Unexpected error {e}" ) ,
719722 }
720723 }
724+
725+ #[ tokio:: test]
726+ async fn test_proxy_send_sync ( ) {
727+ fn assert_send_sync ( _x : impl Send + Sync ) { }
728+
729+ let Ok ( proxy) = ImageProxy :: new ( ) . await else {
730+ // doesn't matter: we only actually care to test if this compiles
731+ return ;
732+ } ;
733+ assert_send_sync ( & proxy) ;
734+ assert_send_sync ( proxy) ;
735+
736+ let opened = OpenedImage ( 0 ) ;
737+ assert_send_sync ( & opened) ;
738+ assert_send_sync ( opened) ;
739+ }
721740}
You can’t perform that action at this time.
0 commit comments