@@ -24,7 +24,7 @@ describe("SSEClientTransport", () => {
24
24
// Send SSE headers
25
25
res . writeHead ( 200 , {
26
26
"Content-Type" : "text/event-stream" ,
27
- "Cache-Control" : "no-cache" ,
27
+ "Cache-Control" : "no-cache, no-transform " ,
28
28
Connection : "keep-alive" ,
29
29
} ) ;
30
30
@@ -56,6 +56,8 @@ describe("SSEClientTransport", () => {
56
56
baseUrl = new URL ( `http://127.0.0.1:${ addr . port } ` ) ;
57
57
done ( ) ;
58
58
} ) ;
59
+
60
+ jest . spyOn ( console , 'error' ) . mockImplementation ( ( ) => { } ) ;
59
61
} ) ;
60
62
61
63
afterEach ( async ( ) => {
@@ -183,7 +185,7 @@ describe("SSEClientTransport", () => {
183
185
if ( req . method === "GET" ) {
184
186
res . writeHead ( 200 , {
185
187
"Content-Type" : "text/event-stream" ,
186
- "Cache-Control" : "no-cache" ,
188
+ "Cache-Control" : "no-cache, no-transform " ,
187
189
Connection : "keep-alive" ,
188
190
} ) ;
189
191
res . write ( "event: endpoint\n" ) ;
@@ -397,7 +399,7 @@ describe("SSEClientTransport", () => {
397
399
398
400
res . writeHead ( 200 , {
399
401
"Content-Type" : "text/event-stream" ,
400
- "Cache-Control" : "no-cache" ,
402
+ "Cache-Control" : "no-cache, no-transform " ,
401
403
Connection : "keep-alive" ,
402
404
} ) ;
403
405
res . write ( "event: endpoint\n" ) ;
@@ -524,7 +526,7 @@ describe("SSEClientTransport", () => {
524
526
if ( auth === "Bearer new-token" ) {
525
527
res . writeHead ( 200 , {
526
528
"Content-Type" : "text/event-stream" ,
527
- "Cache-Control" : "no-cache" ,
529
+ "Cache-Control" : "no-cache, no-transform " ,
528
530
Connection : "keep-alive" ,
529
531
} ) ;
530
532
res . write ( "event: endpoint\n" ) ;
@@ -610,7 +612,7 @@ describe("SSEClientTransport", () => {
610
612
611
613
res . writeHead ( 200 , {
612
614
"Content-Type" : "text/event-stream" ,
613
- "Cache-Control" : "no-cache" ,
615
+ "Cache-Control" : "no-cache, no-transform " ,
614
616
Connection : "keep-alive" ,
615
617
} ) ;
616
618
res . write ( "event: endpoint\n" ) ;
0 commit comments