File tree Expand file tree Collapse file tree 1 file changed +5
-7
lines changed
src/Servers/HttpSys/test/FunctionalTests Expand file tree Collapse file tree 1 file changed +5
-7
lines changed Original file line number Diff line number Diff line change @@ -109,6 +109,9 @@ public async Task ConnectionClose_OSSupport_SendsGoAway()
109
109
110
110
await http2Utilities . StartStreamAsync ( 1 , Http2Utilities . _browserRequestHeaders , endStream : true ) ;
111
111
112
+ var goAwayFrame = await http2Utilities . ReceiveFrameAsync ( ) ;
113
+ http2Utilities . VerifyGoAway ( goAwayFrame , int . MaxValue , Http2ErrorCode . NO_ERROR ) ;
114
+
112
115
var headersFrame = await http2Utilities . ReceiveFrameAsync ( ) ;
113
116
114
117
Assert . Equal ( Http2FrameType . HEADERS , headersFrame . Type ) ;
@@ -123,20 +126,15 @@ public async Task ConnectionClose_OSSupport_SendsGoAway()
123
126
Assert . False ( decodedHeaders . ContainsKey ( HeaderNames . Connection ) ) ;
124
127
Assert . Equal ( "200" , decodedHeaders [ HeaderNames . Status ] ) ;
125
128
126
- var goAwayFrame = await http2Utilities . ReceiveFrameAsync ( ) ;
127
- http2Utilities . VerifyGoAway ( goAwayFrame , 1 , Http2ErrorCode . NO_ERROR ) ;
128
-
129
- await http2Utilities . SendGoAwayAsync ( ) ;
130
- // TODO: Close the connection?
131
- // await http2Utilities.StopConnectionAsync(expectedLastStreamId: 1, ignoreNonGoAwayFrames: false);
129
+ await http2Utilities . StopConnectionAsync ( expectedLastStreamId : 1 , ignoreNonGoAwayFrames : false ) ;
132
130
133
131
logger . LogInformation ( "Connection stopped." ) ;
134
132
} ;
135
133
} ) ;
136
134
} )
137
135
. Build ( ) ;
138
136
139
- await host . RunAsync ( ) ;
137
+ await host . RunHttp2CatAsync ( ) ;
140
138
}
141
139
}
142
140
}
You can’t perform that action at this time.
0 commit comments