Spike - research which mock server would be the best to integrate with Pact and BigTest
Description
Environment
Potential Workaround
relates to
Checklist
hideTestRail: Results
Activity

Khalilah Gambrell August 31, 2018 at 12:35 PM
@Oleksii Popov and @Tetyana Afanasyeva, I am marking this as done. Based on feedback from the demo, we may add additional user stories to the backlog.

Matt Reno August 30, 2018 at 9:38 PM
I've looked at the Pact PoC repos and they demonstrate basic Pact consumer/producer generation/verification using existing Pact related generation/verification libraries.
I don't know if all the acceptance criteria are met as I am not familiar with BigTest. I don't see anything in the consumer code to suggest BigTest is being used as the test harness (it appears to be chai).
Otherwise, I think a demo of this could evoke several questions about how we can integrate it in the actual CI/CD pipeline, which is a good thing.

Anton Emelianov August 30, 2018 at 6:50 PM
@Khalilah Gambrell, Code review should be done by @Matt Reno. The actual demo is scheduled on Tuesday 9/2

Khalilah Gambrell August 30, 2018 at 12:30 PM
Hey @Anton Emelianov, we need you to confirm that the work for this user story is done. What is the best way for you to confirm?

Oleksii Popov August 29, 2018 at 12:44 PM
Pact serves well with its concept of contract testing.
Interaction explained and tested for both FE and BE side.
As a result of consumer (FE) test a special pact contract file is created (.json). Such files describe an interaction between consumer and provider (it can be FE+BE or two interacting BE modules).
Pact consumer (JavaScript) for demo session implemented here: https://github.com/oleksii-popov/pact-simple-consumer (includes authn/login and pact contract generation)
Pact provider test (Java) for serverside implemented here: https://github.com/Igor-Gorchakov/simplepact (OKAPI authn/login test, based on pact contract)
Will be shown on next UI testing meeting.
FYi @Anton Emelianov @Khalilah Gambrell @Ann-Marie Breaux
Details
Details
Assignee

Reporter

Currently, BigTest employs Mirage for its client-side mock server. Mirage doesn't support Pact integration out of the box. We need BigTest UI testing framework to support consumer-driven contract tests. The additional complexity is added by the fact that UI makes REST API request via Okapi ( not directly to an end-point published by producer module)
The goal of this story is to research what would be the best option:
1) Modify Mirage to support Pact
2) Figure out if a different mock server that supports Pact out of the box can be integrated with Pact.
Acceptance criteria:
1) Working demo of BigTest test that is using test-doubles that are captured into Pact files and stored on the Pact server
2) Test case for corresponding producer module that uses the same Pact file as mock.
3) Break a contract on producer side --> Modify Pact file --> prove that test failed on the BigTest side.