-
-
Notifications
You must be signed in to change notification settings - Fork 4.2k
Events: fix numeric
operator string handling and provider validation for TestEventPattern
#11994
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
Conversation
LocalStack Community integration with Pro 2 files ± 0 2 suites ±0 1h 9m 14s ⏱️ - 40m 25s Results for commit 68a699b. ± Comparison against base commit 6df4dbc. This pull request removes 1547 and adds 8 tests. Note that renamed tests count towards both.
♻️ This comment has been updated with latest results. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Wow, amazing edge case coverage ✨ 💯
Motivation
As reported in #11992, there might have been issue with the new engine rule engine.
I could only reproduce the
test_dynamodb_event_filter[numeric_filter]
failure, which was due to our bad handling ofnumeric
logic with string values.While validating the fix and the handling of the new EventRuleEngine for
test_sqs_event_filter[this is a test string]
, the behavior was right, but the validation forTestEventPattern
was wrong.I've also validated that
test_dynamodb_event_filter[numeric_filter]
now works with the fix 👍Then, when validating the DynamoDB fix, I've tried to copy-paste the input event from ESM, but it failed when calling
TestEventPattern
because the event was not following the right format, so I've added it in the provider to also validate this, as specified by the documentation here: https://docs.aws.amazon.com/eventbridge/latest/APIReference/API_TestEventPattern.html (note, theresources
field is not mandatory in reality).Changes
numeric
if the value is a string (or more like the value is not a numeric value)TestEventPattern
provider operationnumeric
fix, and the provider validation