File tree Expand file tree Collapse file tree 2 files changed +0
-62
lines changed Expand file tree Collapse file tree 2 files changed +0
-62
lines changed Original file line number Diff line number Diff line change @@ -267,12 +267,6 @@ class QUICConnection extends EventTarget {
267267 } ,
268268 @context ctx : ContextTimed ,
269269 ) : Promise < QUICConnection > {
270- const timeoutTime = ctx . timer . getTimeout ( ) ;
271- if ( timeoutTime !== Infinity && timeoutTime >= args . config . maxIdleTimeout ) {
272- throw new errors . ErrorQUICConnectionInvalidConfig (
273- 'connection timeout timer must be strictly less than maxIdleTimeout' ,
274- ) ;
275- }
276270 ctx . signal . throwIfAborted ( ) ;
277271 const abortProm = promise < never > ( ) ;
278272 const abortHandler = ( ) => {
Original file line number Diff line number Diff line change @@ -280,62 +280,6 @@ describe(QUICClient.name, () => {
280280 ) ,
281281 ) . rejects . toThrow ( errors . ErrorQUICClientCreateTimeOut ) ;
282282 } ) ;
283- test ( 'ctx timer must be less than maxIdleTimeout' , async ( ) => {
284- // Larger timer throws
285- await expect (
286- QUICClient . createQUICClient (
287- {
288- host : localhost ,
289- port : 56666 ,
290- localHost : localhost ,
291- crypto : {
292- ops : clientCrypto ,
293- } ,
294- logger : logger . getChild ( QUICClient . name ) ,
295- config : {
296- maxIdleTimeout : 200 ,
297- verifyPeer : false ,
298- } ,
299- } ,
300- { timer : 1000 } ,
301- ) ,
302- ) . rejects . toThrow ( errors . ErrorQUICConnectionInvalidConfig ) ;
303- // Smaller keepAliveIntervalTime doesn't cause a problem
304- await expect (
305- QUICClient . createQUICClient (
306- {
307- host : localhost ,
308- port : 56666 ,
309- localHost : localhost ,
310- crypto : {
311- ops : clientCrypto ,
312- } ,
313- logger : logger . getChild ( QUICClient . name ) ,
314- config : {
315- maxIdleTimeout : 200 ,
316- verifyPeer : false ,
317- } ,
318- } ,
319- { timer : 100 } ,
320- ) ,
321- ) . rejects . not . toThrow ( errors . ErrorQUICConnectionInvalidConfig ) ;
322- // Not setting an interval doesn't cause a problem either
323- await expect (
324- QUICClient . createQUICClient ( {
325- host : localhost ,
326- port : 56666 ,
327- localHost : localhost ,
328- crypto : {
329- ops : clientCrypto ,
330- } ,
331- logger : logger . getChild ( QUICClient . name ) ,
332- config : {
333- maxIdleTimeout : 200 ,
334- verifyPeer : false ,
335- } ,
336- } ) ,
337- ) . rejects . not . toThrow ( errors . ErrorQUICConnectionInvalidConfig ) ;
338- } ) ;
339283 test ( 'client times out with ctx signal while starting' , async ( ) => {
340284 // QUICClient repeatedly dials until the connection timeout
341285 const abortController = new AbortController ( ) ;
You can’t perform that action at this time.
0 commit comments