@@ -30,7 +30,7 @@ describe(relative(process.cwd(), __filename), async () => {
3030 await moxy . close ( { closeConnections : true } ) ;
3131 } ) ;
3232
33- await it ( 'can configure routes' , async ( ) => {
33+ await it ( 'can configure routes' , async ( context ) => {
3434 await request . get ( '/example-routing/12345/measurements/76543' ) . expect ( 404 ) ;
3535 await request . get ( '/example-routing/static/image.png' ) . expect ( 404 ) ;
3636 await request . post ( '/example-routing/auth/login' ) . expect ( 404 ) ;
@@ -51,7 +51,7 @@ describe(relative(process.cwd(), __filename), async () => {
5151 const proxy = new MoxyServer ( { logging : 'error' } ) ;
5252 proxy . on ( '/test\\?q=asdf' , { get : { status : 418 } } ) ;
5353 await proxy . listen ( ) ;
54- after ( ( ) => proxy . close ( { closeConnections : true } ) ) ;
54+ context . after ( ( ) => proxy . close ( { closeConnections : true } ) ) ;
5555
5656 assert . deepStrictEqual ( routeConfig [ 'proxied-server(?<path>.*)' ] as PathConfig , {
5757 proxy : 'https://www.google.com:path' ,
@@ -342,12 +342,12 @@ describe(relative(process.cwd(), __filename), async () => {
342342 assert . strictEqual ( Date . now ( ) - start >= 100 , true ) ;
343343 } ) ;
344344
345- await it ( 'can proxy requests to another server' , async ( ) => {
345+ await it ( 'can proxy requests to another server' , async ( context ) => {
346346 const proxyTarget = new MoxyServer ( { logging : 'error' } ) ;
347347 await proxyTarget . listen ( 0 ) ;
348- after ( async ( ) => {
349- await proxyTarget . close ( { closeConnections : true } ) ;
350- } ) ;
348+ /* eslint-disable-next-line no-console */
349+ console . log ( { nodeV : process . env . NODEV , port : proxyTarget . server ?. address ( ) } ) ;
350+ context . after ( ( ) => proxyTarget . close ( { closeConnections : true } ) ) ;
351351
352352 proxyTarget . on ( '/this/request/was/proxied' , {
353353 get : {
0 commit comments