Skip to content

Commit 58be64a

Browse files
author
Danil Nurgaliev
committed
feat: Add buildUrl option to Pact Broker Publishing API
1 parent 85f0b92 commit 58be64a

File tree

3 files changed

+4
-0
lines changed

3 files changed

+4
-0
lines changed

README.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -313,6 +313,7 @@ pact.publishPacts(opts).then(function () {
313313
| `pactBrokerPassword` | false | string | Password for Pact Broker basic authentication. Optional |
314314
| `pactBrokerToken` | false | string | Bearer token for Pact Broker authentication. Optional |
315315
| `tags` | false | array | An array of Strings to tag the Pacts being published. Optional |
316+
| `buildUrl` | false | string | The build URL that created the pact. Optional |
316317
| `verbose` | false | boolean | Enables verbose output for underlying pact binary. |
317318

318319
### Pact Broker Deployment Check

src/publisher.ts

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,7 @@ export class Publisher {
1818
tags: '--tag',
1919
consumerVersion: '--consumer-app-version',
2020
verbose: '--verbose',
21+
buildUrl: '--build-url',
2122
};
2223

2324
constructor(options: PublisherOptions) {
@@ -148,4 +149,5 @@ export interface PublisherOptions {
148149
tags?: string[];
149150
verbose?: boolean;
150151
timeout?: number;
152+
buildUrl?: string;
151153
}

test/publisher.integration.spec.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -37,6 +37,7 @@ describe('Publish Spec', () => {
3737
),
3838
],
3939
consumerVersion: '1.0.0',
40+
buildUrl: 'http://ci/build/1',
4041
});
4142

4243
expect(publisher).to.be.a('object');

0 commit comments

Comments
 (0)