Repository navigation
Add CI that tests the SES, SQS and SNS examples - #4
Merged
Merged
Conversation
Fix the SQS sample order and the SES topic lookup, add a make test target and test.sh per example, and run all three in a GitHub Actions matrix. Claude-Session: https://claude.ai/code/session_01DZfDmzUBPqNAu3yFKyfCNM
lstk cdk looks for cdk on PATH, which only has it after a global install. The SES test prints the describe-configuration-set and sesv2 responses to show where the event destination is missing. Claude-Session: https://claude.ai/code/session_01DZfDmzUBPqNAu3yFKyfCNM
LocalStack returns an empty EventDestinations list from describe-configuration-set and does not implement the sesv2 read, so the test relies on make setup-all failing if the create fails. Give the SQS test more time, since retries in one FIFO message group run in sequence. Claude-Session: https://claude.ai/code/session_01DZfDmzUBPqNAu3yFKyfCNM
remotesynth
approved these changes
Oct 13, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The repo had no CI and no tests, and the SQS sample order could not be processed.
Fixes:
sqs/sampleData/order.jsonsent items withname, but OrderManager readsitemDetail. The DynamoDB document client rejected the undefined value, somake test-orderfailed before anything reached the queue. The data now usesitemDetail.itemIdwhen the order gives one. The sample's IDs (ITEM-101, ITEM-223) are the ones the README's failure rules describe.sqsgetsesbuildas a dev dependency, socdk deploybundles locally instead of in Docker.sqsandsnsMakefiles putnode_modules/.binon PATH.lstk cdkrunscdkfrom PATH, somake deployfailed with "cdk not found in PATH" without a global install.ses/Makefileresolved the topic ARN fromaws configure get regionand fell back to plainawswithout the LocalStack endpoint. It now useslstk aws sns create-topic, which returns the existing topic.sns/README.md: phone numbers in E.164 format, a placeholder instead of a real API ID, andContent-Type: application/jsonon the filter examples. Without it, LocalStack's API Gateway re-encodes the body as form data and the Lambda cannot parse it.Tests, run with
make testin each example:ses: runsmake setup-all, checks the sender is verified, the configuration set exists, and the email subscription is confirmed. Sends a text and an HTML email and reads both back from/_aws/ses.sqs: submits the sample order under a unique ID, checks the order total, then waits until ITEM-223 isFAILEDthrough the DLQ, ITEM-101 isPROCESSEDorFAILED, and the other items arePROCESSED.sns: publishes four events through the API, checks each subscriber Lambda's logs only contain the events its filter policy allows, that ops-alerts published to its topic, and that SMS messages were sent. Also checks an invalid event type returns 400.The SES test does not read back the event destination. On LocalStack,
describe-configuration-setwitheventDestinationreturns an emptyEventDestinationslist after a successfulcreate-configuration-set-event-destination, andsesv2 get-configuration-set-event-destinationsis not implemented.make setup-allstill fails if the create fails.New workflow runs the three examples in a matrix: start LocalStack with lstk, deploy the CDK stack for sqs and sns, then
make test.Verified by CI.
https://claude.ai/code/session_01DZfDmzUBPqNAu3yFKyfCNM