pact-foundation / pact_broker

Enables your consumer driven contracts workflow
http://pactflow.io
MIT License
708 stars 176 forks source link

chore: clean up decorator context #645

Closed bethesque closed 1 year ago

bethesque commented 1 year ago

The original purpose of the DecoratorContext was to provide the decorators with an object that could be used as the user_options for getting things like the base URL, resource URL, resource title etc.

Unfortunately, this never panned out, as the Roar::Decorator code calls merge on the user_options object (expecting it, quite reasonably, to be a Hash), and it turns back into a Hash by the time it gets yielded into the decorator blocks.

This PR cleans up and documents that code.