Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add S3 test event #163

Merged
merged 4 commits into from
Feb 19, 2019
Merged

Add S3 test event #163

merged 4 commits into from
Feb 19, 2019

Conversation

LegNeato
Copy link
Contributor

@LegNeato LegNeato commented Jan 31, 2019

As seen in https://docs.aws.amazon.com/AmazonS3/latest/dev/notification-content-structure.html.

I didn't write a test as they are set up for a 1-1 mapping between event and service. Happy to add one, but it will take some test refactoring and for this simple struct that is never used in production I thought it likely wasn't worth it.

@codecov-io
Copy link

codecov-io commented Jan 31, 2019

Codecov Report

Merging #163 into master will not change coverage.
The diff coverage is n/a.

Impacted file tree graph

@@          Coverage Diff           @@
##           master    #163   +/-   ##
======================================
  Coverage    69.8%   69.8%           
======================================
  Files          18      18           
  Lines         679     679           
======================================
  Hits          474     474           
  Misses        165     165           
  Partials       40      40

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update dcf76fe...ab347d4. Read the comment docs.

events/s3.go Show resolved Hide resolved
sample event:
```
{"Service":"Amazon S3","Event":"s3:TestEvent","Time":"2019-02-04T19:34:46.985Z","Bucket":"bmoffatt","RequestId":"7BA1940DC6AF888B","HostId":"q1YDbiaMjllP0m+Lcy6cKKgxNrMLFJ9zCrZUFBqHGTG++0nXvnTDIGC7q2/QPAsJg86E8gI7y9U="}
```
@bmoffatt
Copy link
Collaborator

bmoffatt commented Feb 4, 2019

I didn't see S3 send the test event to my Lambda function in testing, but could for SQS 🤷‍♂️

@LegNeato
Copy link
Contributor Author

Right, but the SQS event appears to include this test event so it would be good to just have the def in the library.

@bmoffatt bmoffatt merged commit 7522090 into aws:master Feb 19, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants