(empty)
| 34 | }; |
| 35 | |
| 36 | function getNotifRequest(empty) { |
| 37 | const queueConfig = empty ? '' : |
| 38 | '<QueueConfiguration>' + |
| 39 | '<Id>notification-id</Id>' + |
| 40 | '<Queue>arn:scality:bucketnotif:::target1</Queue>' + |
| 41 | '<Event>s3:ObjectCreated:*</Event>' + |
| 42 | '<Event>s3:ObjectTagging:*</Event>' + |
| 43 | '<Event>s3:ObjectAcl:Put</Event>' + |
| 44 | '</QueueConfiguration>'; |
| 45 | |
| 46 | const notifXml = '<NotificationConfiguration xmlns="http://s3.amazonaws.com/doc/2006-03-01/">' + |
| 47 | `${queueConfig}` + |
| 48 | '</NotificationConfiguration>'; |
| 49 | |
| 50 | const putNotifConfigRequest = { |
| 51 | bucketName, |
| 52 | headers: { |
| 53 | host: `${bucketName}.s3.amazonaws.com`, |
| 54 | }, |
| 55 | post: notifXml, |
| 56 | actionImplicitDenies: false, |
| 57 | }; |
| 58 | return putNotifConfigRequest; |
| 59 | } |
| 60 | |
| 61 | describe('putBucketNotification API', () => { |
| 62 | before(cleanup); |
no outgoing calls
no test coverage detected