https://pact.io logo
Join Slack
Powered by
# general
  • v

    Viktoriia Vlasiuk

    01/10/2023, 8:53 AM
    Hello! I've got a general question regarding provider verification step. What happens when you run it? Is a test request gets generated from the pulled pact and goes through the providers handlers? We have argues in the team regarding whether it is the same when you run provider verification tests and when you generate provider's spec, push it to pactflow and let it to compare the consumer's and provider's pacts.
    b
    t
    a
    • 4
    • 29
  • a

    Anandhi Muthukumarasamy

    01/10/2023, 8:12 PM
    Hi Team, I am a QE and have just started learning about Pact and looking for possibilities to introduce it to our team. Do we have to write Pact tests close to the dev code only? Can we write contract tests in a different repo (other than dev repo) using Pact/Cypress? Would it still serve the purpose?
    m
    • 2
    • 4
  • s

    Siddharth Gupta

    01/11/2023, 9:20 AM
    HI , We have a two software components A & B. Communication is unidirectional from A to B . B is the consumer or lets say it subscribes\registers with A and A sends data to B on certain events on database . How can we implement Consumer driven Contrat testing in this case .I guess similar would be the case for software components which registers on a message bus
    t
    m
    • 3
    • 5
  • l

    Laurence Cruz

    01/12/2023, 7:08 PM
    hi all -- I'm trying to find the talk / it might've been a podcast or video that made a specific reference to "collaborative" testing. I'm sure this is probably referenced across multiple talks but I can't seem to pinpoint which one it was 😅
    t
    • 2
    • 1
  • y

    Yusuf Azam

    01/17/2023, 12:29 PM
    Hello I have a general question. I publish a pact with my consumer that has changes, it runs the webhook and trigger a workflow in the provider verification step. The consumer build however on can-i-deploy says there is no verification for this pact. Do I have to wait for the broker to return the verified pact as part of my ci.?
    y
    • 2
    • 3
  • r

    Richard McCann

    01/17/2023, 3:11 PM
    Hi, I have a question about implementing Pact. I have been investigating Pact as a POC for a multi team project where the Consumer and Provider teams will be separate. I have created the POC following the best practice for CI/CD as described in the Pact documentation. There is one thing that I think will be a blocker for us to implement Pact and contract tests which is that the necessity of the Consumer code creating (or updating) the the contract first means that this work done by the Consumer team is left in limbo - it cannot be merged into the main branch and must be shelved until the Provider team 'get around' to fulfilling the contract. Under our definition of done this leaves that piece of work incomplete, and dependent on another team before it can be completed. We have tried to remove dependencies like this between teams as the teams are not always at liberty to drop what they are currently working on and so it may be some time before the provider work is done, leaving the Consumer code going stale on a branch. For reference the current process would be that the Provider team would develop the interaction first, test and merge to main, completing their story. The Consumer team could then implement the usage of the feature with no dependency on the Provider team. I would be interested to hear if others have faced this and how they have addressed it or what would the recommended approach be?
    t
    b
    • 3
    • 12
  • k

    komathypriya

    01/17/2023, 5:32 PM
    Hi Team, we are planning to use PACT for API Testing. Wanted to know is there a license involved in using PACTbrokers and Pact io? If so where can i look at that. If not, if Pact being a Open source how the PACTs are secured when its published in PACT io?
    b
    m
    t
    • 4
    • 7
  • k

    komathypriya

    01/17/2023, 5:34 PM
    PACT been recently acquired by Smartbear. Smart bear has a tool called Ready API, whats the difference being both API testing tools. We are opting for PACT, so trying to understand the benefits of PACT over Ready API.
    t
    m
    y
    • 4
    • 5
  • k

    komathypriya

    01/17/2023, 5:35 PM
    Can anyone help me on my decision ques
  • k

    komathypriya

    01/17/2023, 5:35 PM
    questions
  • n

    Nick Meyer

    01/17/2023, 5:49 PM
    Hi all, I’m having an issue and need some perspective/guidance. We are introducing a new provider service, and we have built the pipeline in to run the provider verification. We run our verification against
    {"deployedOrReleased": true}
    as we deploy to staging upon merge to main (assuming tests pass). Since we don’t have the provider in place yet, there’s no consumer test deployed against it. Unfortunately, running a
    can-i-deploy
    check fails with
    Copy code
    Computer says no ¯_(ツ)_/¯
    
    No pacts or verifications have been published for version XXX of XXX
    To me, this shouldn’t be a failure. Am I missing something?
    • 1
    • 1
  • h

    Hunter

    01/17/2023, 9:18 PM
    Hello quick question, our organization is using RDF(Turlte)/JSONLD for response types from our APIs vs just a standard static json response, is this type of testing possible with pactflow?
  • j

    Jean Paiva

    01/18/2023, 6:41 PM
    Hey everyone, is it possible to use pact-verifier to verify async communication (messages)? Should it work as long I return the response through an endpoint? I am just asking because it seems like sync pact use an array of interactions, and for async, it seems like we use
    messages
    . Would I be able to use it in a scenario like this?
    m
    • 2
    • 2
  • h

    Hazem Borham

    01/18/2023, 10:02 PM
    Hey all, I haven't quite found a nice pattern to define consumer pacts when the provider schema with proto3 type
    oneof
    ? Curious if anyone has any matching examples for the following
    Copy code
    message FooResponse {
      string description = 1;
      repeated Field fields = 2;
    }
    message Field {
      string id = 1
      oneof field_data {
        TextField textInput = 6;
        ChoiceField choiceInput = 7;
      }
    }
    example json to match on
    Copy code
    {
      "description": "foo",
      "fields": [
        {
          "id": "123",
          "textInput": {}
        },
        {
          "id": "123",
          "choice": {}
        }
      ]
    }
    u
    • 2
    • 6
  • d

    davT

    01/20/2023, 3:07 PM
    Afternoon , I have set up a PactFlow integration with my SwagerHub, I have the correct URL and Token and have assigned a PactFlow Applications (which appeared in the relevant drop down - I assigned my consumer here - is this correct ? ) and created the integration. When I check "Check Compatibility" I see 'Compatible' but when I click "view compatibility result' I see "_This API does not yet have any consumer contracts_". Why is this , I have a contract in PactFlow which is assigned in the integration , would anyone know how to fix this error ? I think I have misunderstood the PactFlow application , could someone define that for me and how topush it to PactFlow . Thanks
    y
    • 2
    • 13
  • n

    Nuno Frias

    01/24/2023, 10:44 AM
    Hi all, I have a contract that checks whether the
    Authorization
    header in the response matches a jwt regex. However when the provider test runs, it seems to be overriding the regex match and doing an exact match. Is there a different behaviour for the
    Authorization
    header ?
    m
    • 2
    • 3
  • y

    Yousaf Nabi (pactflow.io)

    01/25/2023, 1:58 PM
    Happy Wednesday everyone! As Pact nears 10 years old (in April!), we are thinking about a birthday party/event to help celebrate it in style, and it wouldn't be a party without you all. We are currently thinking of ideas, so if we have any party-planners in the house, or any ideas, feel free to give me a shout. To kick it off, I'm really keen to try and get some local meetup's arranged globally, we have so many little Pact communities in far-reaching places, so ill start off with a couple of questions. • Where are you from in the world? • Would you be keen to attend, help organise or organise a local event? we aren't necessarily looking for Pact experts, anyone with an interest in Pact would be welcome ( I didn't say anyone as I can imagine AirBnB style internet party take-overs where 500 ravers turn up 😅 )
    j
    j
    +3
    • 6
    • 10
  • t

    Tatiana

    01/26/2023, 6:26 PM
    Hi All! I have a question regarding provider verification. I would like to achieve the following: • Webhook triggers the provider verification when a contract was changed and published from the consumer merge request. The provider should take the contract published from the consumer’s merge request or the latest published contract. • When provider opens a merge request then the verification should happen for the contract which was published from the consumer’s main branch. I created a webhook in PactFlow and it triggers the verification anytime when the contract is changed/published. However, I can’t come up with the idea how to achieve the described scenarios above. I was thinking to provide a
    --consumer-version-tags="main"
    for provider verification job but then the first scenario won’t work, the provider will always take the contract with
    main
    tag which is assigned after merge to the main branch. Also, I can create two verification jobs for provider, one will be triggered by webhook only, another one will run when merge request is opened from provider. But it doesn’t look great. Do you have any ideas how I can achieve my desired result described above? Maybe I can play with tags somehow or pass something to my webhook? Please advice 🙂
    m
    y
    • 3
    • 15
  • m

    Mark Wilson

    01/27/2023, 12:41 PM
    Hi guys Im getting a 401 when trying to publish an openapi spec from the provider side using
    pactflow publish-provider-contract
    using pact_broker-client-1.66.1 locally. I know the broker-base-url and broker-token are fine as I can publish the consumer contract just fine. Any ideas?
    👋 1
    y
    t
    e
    • 4
    • 7
  • s

    Shawn Erquhart

    01/27/2023, 7:08 PM
    Hi all. I've been working extensively with Pact, MSW, and the rust implementation of pact mock server to run Jest tests against our generated pact files. I've looked at the msw adapter and I'm hoping to get some understanding on two things: 1. Doesn't generating pact files from UI test interactions violate Pact's warnings against writing contracts based on UI test cases? 2. Pact provides an API for clearly identifying exact values vs. types of values that may change via matchers - I would expect generated test cases to either be too exact or too loose. Can we really generate quality contracts this way? I guess I'm trying to understand if we're losing significant value by using this adapter. I'm interested in the efficiency of it, though. Any insights are appreciated!
    t
    m
    • 3
    • 17
  • y

    Yair Shkedi

    01/30/2023, 8:39 AM
    Hi all, and thanks for helping in advance. In the company that I working for, contract tests were added, it understood why we need it and the value. We have a use case that was talked in our company and we would like to hear the opinion here from the pact’s experts, to understand what better to do. Use case: A msg contract was added. There is a service, that is kind of monolit, the service also send msg (by queue) and the same service consume this queue (maybe other instance). Question: Should we create a contract test for this use case? From one side: it more sensible that contract should be between 2 services. From the other side: this is a big service and we still want to verify that nothing break. Would like to hear your opinon. @Arnon Ram FYI
    m
    • 2
    • 2
  • u

    Ulises Cervino

    01/30/2023, 2:28 PM
    hi all, I have a question about consumer tests: does it make sense, in general, for a consumer to write a test that expresses something like "when I fetch an entity with ID 1, e.g. GET /entity/1, I expect a response entity in json, and the field id in there should also have the value 1"?
  • u

    Ulises Cervino

    01/30/2023, 2:29 PM
    you can check via regexes that the string in field "id" is exactly "1", but that doesn't work with provider states (or at least I couldn't figure out how to make it work) since the pact has the hardcoded string "1", and not as an example
    b
    m
    u
    • 4
    • 53
  • u

    Ulises Cervino

    01/30/2023, 7:39 PM
    another question: how do you folk agree on naming? not just participants' names, but provider states, variable names, etc.?
  • u

    Ulises Cervino

    01/30/2023, 7:39 PM
    we're in a situation in which we have several teams writing consumer tests, while others are writing provider tests, and right now the solution to that is to "hop on a zoom call" but that's ad-hoc a best
    b
    y
    m
    • 4
    • 38
  • j

    Jay Li

    01/31/2023, 2:36 AM
    Guys, why my webhook is always Not Run??? I changed the contract, and I can also manually kick off wehook, how come my webhook status is always Not Run? And it is not automatically triggered either. Anyone can give me some clue? Thanks in advance.
    b
    m
    y
    • 4
    • 6
  • b

    Bhavyashree R

    02/01/2023, 8:52 AM
    Hi.. Is it possible to host pact broker centrally without using pactflow ? If yes can someone please help me with the steps .
    m
    b
    • 3
    • 2
  • g

    Gustavo Souza

    02/01/2023, 3:17 PM
    Hey there! Do we have a documentation about how to setup pact at github actions?!
    y
    • 2
    • 9
  • b

    Basu Silviu

    02/01/2023, 4:43 PM
    hi guys - is there a way to separate the publishing of the provider results back to the broker from the actual run of the provider tests? (somehow similar to running consumer tests and publishing them in the broker)
    y
    • 2
    • 3
  • e

    Eddie Stanley

    02/01/2023, 10:47 PM
    For pact verifier (provider) implementations, what is the expected behaviour if a given interaction is missing the
    providerState
    key? Should the verifier still make a call to the provider-states endpoint or should it skip doing that and go directly to making the request defined by the interaction? See related question in #C9UTHV2AD.
1...131415...18Latest