-
Notifications
You must be signed in to change notification settings - Fork 2
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
Custom auth in failure function #28
Conversation
initial payload is still accessible through context.initialPayload
run state would become run_success. now it becomes run_canceled
they are disabled because they are unreliable in CI. will run locally instead.
when retry was 0, it wasn't being set because of 'if (retries)'. in context.call, if the endpoint we call returns an undefined body, the body field in the callback is not set. We replace this with empty string.
redis.fail allows us to mark a test as failed. if it's called, checkRedisForResults will fail.
await redis.increment(route, randomId) | ||
await redis.saveResultsWithoutContext(route, randomId, result) | ||
await redis.checkRedisForResults(route, randomId, 1, result) |
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.
Why do we check this? We already know it'd work
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.
just a checkpoint to make sure that the state is set in redis, and only difference is the failWithoutContext
method
Run custom auth in failureFunction by default.
also fixes:
(retries)
, so when it was set to 0, it wasn't being set properly.