surpher / surpher/PactSwiftMockServer
Bug: ...
Nobody has claimed this yet.
- Dominant language
- C
- Stars
- 5
- Forks
- 6
- PR merge metrics
- No merged PRs in 30d
Description
🌎 Environment
- Xcode: 15.2.0
- Platform: MacOS/Vapor
- Version/Release: 0.3.8
- Dependency manager: SPM
💬 Description
At point of calling public func finalize(pact: Data, completion: ((Result<String, MockServerError>) -> Void)?) my pact data has the correct consumer and provider (as far as i can tell. I am debugging up to the point I can, i can see the consumer and provider set as I expect)
The end result however is a file that is called consumer.provider.json that does not match my expected output file. It also does not overwrite/merge changes and finally the content of the file ends up looking like
"consumer": {
"name": "consumer"
},
🦶 Reproduction Steps
Reproduction steps are tricky - we are using this is a VAPOR API, not an xcode project and therefor have some extra wrappers. However i can see my data all the way down to this level, then it suddenly changes.
🤔 Expected Results
"consumer": {
"name": "consumer"
}, should end up with name matching what i have set the consumer to be, not defaulted to consumer.
😲 Actual Results
"consumer": {
"name": "consumer"
} name has defaulted to consumer
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start at the Swift finalize(pact:completion:) entry point and trace how the pact data is passed into the libpact_ffi-backed output. Reproduce with Xcode 15.2, macOS/Vapor, version 0.3.8, and SPM; done means the generated consumer.provider.json preserves the configured consumer name and expected pact content.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- c, swift
- Domain
- testing
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100