I have mounted an engine in my rails app. In a controller, I can access the engine path helpers by prefixing the path with the name of the engine e.g. myengine.articles_path. I want to access these helpers in a service class. Normally I would include the url_helpers i.e.
class SomeService
include Rails.application.routes.url_helpers
end
This allows me to access the helpers in my main app, e.g. root_path, but if I try myengine.articles_path I get
undefined local variable or method `myengine'
How do I access the engine path helpers in a service class or some module like that?