@@ -30,26 +30,28 @@ beforeAll(() => CF.describeStacksPromised({ StackName: stackName })
30
30
} )
31
31
) ;
32
32
33
- it ( 'should setup CORS support with simple string config' , ( ) => fetch ( `${ endpointBase } /simple-cors` , { method : 'OPTIONS' } )
34
- . then ( ( response ) => {
35
- const headers = response . headers ;
36
-
37
- expect ( headers . get ( 'access-control-allow-headers' ) )
38
- . to . equal ( 'Content-Type,X-Amz-Date,Authorization,X-Api-Key,X-Amz-Security-Token' ) ;
39
- expect ( headers . get ( 'access-control-allow-methods' ) ) . to . equal ( 'OPTIONS,GET' ) ;
40
- expect ( headers . get ( 'access-control-allow-origin' ) ) . to . equal ( '*' ) ;
41
- } )
33
+ it ( 'should setup CORS support with simple string config' , ( ) =>
34
+ fetch ( `${ endpointBase } /simple-cors` , { method : 'OPTIONS' } )
35
+ . then ( ( response ) => {
36
+ const headers = response . headers ;
37
+
38
+ expect ( headers . get ( 'access-control-allow-headers' ) )
39
+ . to . equal ( 'Content-Type,X-Amz-Date,Authorization,X-Api-Key,X-Amz-Security-Token' ) ;
40
+ expect ( headers . get ( 'access-control-allow-methods' ) ) . to . equal ( 'OPTIONS,GET' ) ;
41
+ expect ( headers . get ( 'access-control-allow-origin' ) ) . to . equal ( '*' ) ;
42
+ } )
42
43
) ;
43
44
44
- it ( 'should setup CORS support with complex object config' , ( ) => fetch ( `${ endpointBase } /complex-cors` , { method : 'OPTIONS' } )
45
- . then ( ( response ) => {
46
- const headers = response . headers ;
45
+ it ( 'should setup CORS support with complex object config' , ( ) =>
46
+ fetch ( `${ endpointBase } /complex-cors` , { method : 'OPTIONS' } )
47
+ . then ( ( response ) => {
48
+ const headers = response . headers ;
47
49
48
- expect ( headers . get ( 'access-control-allow-headers' ) )
49
- . to . equal ( 'Content-Type,X-Amz-Date,Authorization,X-Api-Key,X-Amz-Security-Token' ) ;
50
- expect ( headers . get ( 'access-control-allow-methods' ) ) . to . equal ( 'OPTIONS,GET' ) ;
51
- expect ( headers . get ( 'access-control-allow-origin' ) ) . to . equal ( '*' ) ;
52
- } )
50
+ expect ( headers . get ( 'access-control-allow-headers' ) )
51
+ . to . equal ( 'Content-Type,X-Amz-Date,Authorization,X-Api-Key,X-Amz-Security-Token' ) ;
52
+ expect ( headers . get ( 'access-control-allow-methods' ) ) . to . equal ( 'OPTIONS,GET' ) ;
53
+ expect ( headers . get ( 'access-control-allow-origin' ) ) . to . equal ( '*' ) ;
54
+ } )
53
55
) ;
54
56
55
57
afterAll ( ( ) => {
0 commit comments