Open shaship04 opened 1 year ago
The way async message tests work, you provide a method that will return the message to be verified, and the Pact framework will call the method and verify the returned message is correct.
In your case, Pact called your verifySuccessMessageEvent
method, but it failed with an exception. That is what the error
Verification Failed - Failed to invoke provider method 'verifySuccessMessageEvent'
means.
Now, to your question could you please help why this exception occured
, I can't comment on that as it is your code that failed, not the Pact framework. You would need to look at the logs to see what the exception was and try work out why your verifySuccessMessageEvent
is failing.
If you are using Spring/Springboot, it could be that a dependency was not wired in correctly.
Verifying a pact between PED_A2CO_MERCHANT_CONFIG_REQUEST [Using File ../pacts/PED_A2CO_MERCHANT_CONFIG_REQUEST-PED.json] Given Merchant-Config create {"TimeStamp":"2023-02-07T23:04:58.676+05:30","message":"[Controller id=0] Processing automatic preferred replica leader election","Thread":"controller-event-thread","Level":"INFO"} generates a message which Verification Failed - Failed to invoke provider method 'verifySuccessMessageEvent'
i am not getting the exact steps and what is this error mean? could you please help why this exception occured.