File tree Expand file tree Collapse file tree 2 files changed +7
-2
lines changed Expand file tree Collapse file tree 2 files changed +7
-2
lines changed Original file line number Diff line number Diff line change @@ -20,11 +20,16 @@ This is the second part of the onboarding tutorial. We will verify a published c
2020
2121* ` PACT_BROKER_TOKEN ` : a valid [ API token] ( https://docs.pactflow.io/#configuring-your-api-token ) for PactFlow
2222* ` PACT_URL ` : a fully qualified domain name with protocol of public tenant ` https://test.pactflow.io `
23+ * ` GIT_COMMIT ` : git SHA which being used as provider version
24+ * ` GIT_BRANCH ` : git branch which being used as provider branch
25+
26+ Alternatively, you can create a ` .env ` file at the project root folder and put the variables in. ie:
2327
24- Alternatively, you can create a ` .env ` file at the project root folder and put the 2 variables in. ie:
2528```
2629PACT_URL=https://test.pactflow.io
2730PACT_BROKER_TOKEN=<<whatever-the-token-you-found>>
31+ GIT_COMMIT="$(git rev-parse HEAD)"
32+ GIT_BRANCH="$(git rev-parse --abbrev-ref HEAD)"
2833```
2934
3035Please note it's ` PACT_URL ` , not ` PACT_BROKER_BASE_URL ` as specified in [ example-consumer] ( https://github.com/pactflow/example-consumer/tree/workshop/pactflow ) . Although they are refering to the same thing.
Original file line number Diff line number Diff line change 77 "start" : " node server.js" ,
88 "test" : " jest --testTimeout 30000 --testPathIgnorePatterns consumerChange.pact.test.js" ,
99 "test:pact" : " jest --testTimeout 30000 --testMatch \" **/*.consumerChange.pact.test.js\" " ,
10- "verify_pacts" : " GIT_COMMIT= \" $(git rev-parse HEAD) \" GIT_BRANCH= \" $(git rev-parse --abbrev-ref HEAD) \" npm run test:pact"
10+ "verify_pacts" : " npm run test:pact"
1111 },
1212 "dependencies" : {
1313 "cors" : " ^2.8.5" ,
You can’t perform that action at this time.
0 commit comments