Hey folks :wave: one of our teams has a project ma...
# general
j
Hey folks 👋 one of our teams has a project making use of bi-directional contract testing using the Pact-Cypress adapter They’re trying to parallelise their Cypress suite to reduce runtime, which means that they end up with several build steps that each generate a consumer contract file Is there a way to publish these individually or do we need to add an additional step that stitches these contract files together into one file?
m
hey! Just an FYI that BDCT is a #CLS16AVEE specific feature. I think you’re best merging the pact files at the end of that and then uploading - does Cypress have a way of doing that?
there is a
--merge
feature on the
pact-broker publish
command that you could also use. But it may result in lots of build triggers so probably not encouraged
j
Sorry for the wrong channel sorry I don’t think Cypress does, it would need to be an extra step in their Github workflow which feels a bit complicated logic-wise I’ll take a look at the
--merge
feature (with caution 😄), I don’t think we make use of the build triggers for that service so it might be what we need
👍 1
Appreciate the help Matt!
👍 1
t
As a hack, you might be able to give each one a different consumer name and include them all in the can-i-deploy query. This is somewhat risky though, as what if you forget to update the query?
j
Thanks Timothy, I did have a similar thought but yeah updating the query worries me 😅 the
--merge
feature so far seems to be the “cleanest” fix