1
1
describe ( 'Enhanced middleware' , ( ) => {
2
2
it ( 'rewrites the response body' , ( ) => {
3
3
cy . visit ( '/static' )
4
- cy . get ( '#message' ) . contains ( 'This was static but has been transformed in' )
4
+ cy . get ( '#message' ) . contains ( 'This was static (& escaping test &) but has been transformed in' )
5
5
cy . contains ( "This is an ad that isn't shown by default" )
6
6
} )
7
7
@@ -10,7 +10,7 @@ describe('Enhanced middleware', () => {
10
10
expect ( response . body ) . to . have . nested . property ( 'pageProps.showAd' , true )
11
11
expect ( response . body )
12
12
. to . have . nested . property ( 'pageProps.message' )
13
- . that . includes ( 'This was static but has been transformed in' )
13
+ . that . includes ( 'This was static (& escaping test &) but has been transformed in' )
14
14
} )
15
15
} )
16
16
@@ -27,13 +27,13 @@ describe('Enhanced middleware', () => {
27
27
28
28
it ( 'handles uppercase i18n redirects properly ' , ( ) => {
29
29
cy . visit ( '/de-DE/static' )
30
- cy . get ( '#message' ) . contains ( 'This was static but has been transformed in' )
30
+ cy . get ( '#message' ) . contains ( 'This was static (& escaping test &) but has been transformed in' )
31
31
cy . contains ( "This is an ad that isn't shown by default" )
32
32
} )
33
33
34
34
it ( 'handles lowercase i18n redirects properly ' , ( ) => {
35
35
cy . visit ( '/de-de/static' )
36
- cy . get ( '#message' ) . contains ( 'This was static but has been transformed in' )
36
+ cy . get ( '#message' ) . contains ( 'This was static (& escaping test &) but has been transformed in' )
37
37
cy . contains ( "This is an ad that isn't shown by default" )
38
38
} )
39
39
} )
0 commit comments