Cloned from downstream: pact-foundation/pact-net#545 (comment)
Version information:
- OS: Linux
- PactNet Version: 5.0.1
- .Net Version: 8
- Pact Broker Version (if applicable): 2.107.1
Describe the bug
Trying to publish test results with provider branch "/refs/head/test", result in an error
2025-07-10T21:23:11.928119Z ERROR ThreadId(01) pact_verifier::pact_broker: Failed to push branch refs/head/test for provider version test
2025-07-10T21:23:11.928223Z ERROR ThreadId(01) pact_verifier: Publishing of verification results failed with an error: Link/Resource was not found - Request to pact broker path '/pacticipants/myprovider/branches/refs%2Fhead%2Ftest/versions/test' failed: 404 Not Found. URL: 'https://pactbroker.com/'
Steps To Reproduce
options.PublishResults(brokerConfig.ProviderVersion, publishOptions =>
{
publishOptions
.BuildUri("http://test")
.ProviderBranch("/refs/head/test");
});
Expected behavior
The provider verification result should be published to a branch with a slash. This is a supported value with the pact cli to publish consumer contract.
Log Output
See above
Additional context
Replacing / with - make it works.
Cloned from downstream: pact-foundation/pact-net#545 (comment)
Version information:
Describe the bug
Trying to publish test results with provider branch "/refs/head/test", result in an error
Steps To Reproduce
Expected behavior
The provider verification result should be published to a branch with a slash. This is a supported value with the pact cli to publish consumer contract.
Log Output
See above
Additional context
Replacing
/with-make it works.