File tree Expand file tree Collapse file tree 1 file changed +14
-5
lines changed Expand file tree Collapse file tree 1 file changed +14
-5
lines changed Original file line number Diff line number Diff line change @@ -65,14 +65,23 @@ function assertUpdates(
6565 secondRequest ,
6666 secondResponse
6767) {
68+ firstResponse = withHeaders ( firstResponse , { foo : 'original' , 'x-other' : 'original' } ) ;
69+ if ( ! firstResponse . status ) {
70+ firstResponse . status = 200 ;
71+ }
72+ secondResponse = withHeaders ( secondResponse , {
73+ foo : 'updated' ,
74+ 'x-ignore-new' : 'ignoreme' ,
75+ } ) ;
76+ if ( ! secondResponse . status ) {
77+ secondResponse . status = 304 ;
78+ }
79+
6880 const headers = notModifiedResponseHeaders (
6981 firstRequest ,
70- withHeaders ( firstResponse , { foo : 'original' , 'x-other' : 'original' } ) ,
82+ firstResponse ,
7183 secondRequest ,
72- withHeaders ( secondResponse , {
73- foo : 'updated' ,
74- 'x-ignore-new' : 'ignoreme' ,
75- } )
84+ secondResponse
7685 ) ;
7786 assert ( headers ) ;
7887 assert . equal ( headers [ 'foo' ] , 'updated' ) ;
You can’t perform that action at this time.
0 commit comments