cloudformation-cli
cloudformation-cli copied to clipboard
Do `cfn test` contract tests handle InProgress?
Do cfn test contract tests process InProgress responses?
I'm running the contract tests on my custom resource and every test fails with
assert status == OperationStatus.SUCCESS, "status should be SUCCESS"
E AssertionError: status should be SUCCESS
The lambda's log for create_create shows
START RequestId: bd3ee212-09d3-4ff1-bc1e-b0e1175bc127 Version: $LATEST
2022/07/14 14:31:22 Handler starting
2022/07/14 14:31:22 Handler received the CREATE action
2022/07/14 14:31:22 Received event: IN_PROGRESS
Message: Create in progress
END RequestId: bd3ee212-09d3-4ff1-bc1e-b0e1175bc127
REPORT RequestId: bd3ee212-09d3-4ff1-bc1e-b0e1175bc127 Init Duration: 0.05 ms Duration: 236.84 ms Billed Duration: 237 ms Memory Size: 256 MB Max Memory Used: 256 MB
2022-07-14 09:31:22 127.0.0.1 - - [14/Jul/2022 09:31:22] "POST /2015-03-31/functions/TypeFunction/invocations HTTP/1.1" 200 -
Invoking handler (go1.x)
Reuse the created warm container for Lambda function 'TypeFunction'
Lambda function 'TypeFunction' is already running
START RequestId: 929cbe74-aade-4c40-b286-d2139d07c2db Version: $LATEST
2022/07/14 14:31:23 Handler received the DELETE action
2022/07/14 14:31:23 Delete: guid: map[]
2022/07/14 14:31:23 Received event: FAILED
Create immediately followed by Delete rather than waiting for Success.
there is a while loop, which runs until handler reaches terminal state - code ref
Thanks @ammokhov , I missed that looking through the code- I'll put some print statements there to see what's going on.
Closing for now but please re-open if you run into this issue again!