You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Oct 11, 2023. It is now read-only.
I naturally want to do rspec testing of my CoAP application.
It also speaks HTTP(S), although I imagine that production that it will be two completely different deploys.
I have changed things so that david is not automatically chosen for "rails server", so that I can develop in both worlds the same time. So one has to do something like: "bin/rails server david -b ::2 -p 5684"
rspec requests skip the framework layer and goes directly to routes. I can test my controllers via config/routes.rb just fine. But I can't test the resource discovery process, doing a GET to /.well-known/core?rt=est.ace to get the location of the resource and then using it.
I propose that the /.well-known/core processing no longer be special cased in lib/david/resource_discovery.rb's call, but instead be referenced in the applications' routes.rb.
The rails5 way might be to use a concern, I see that this how active-scaffold has gone, but the old rails4 "as_routes" may work as well for this.
The text was updated successfully, but these errors were encountered:
I am not sure if adding the route completely manually is a good solution. However, I see the problem with /.well-known/core being provided by a middleware and therefor not having a proper route.
Automatically adding routes does not seem to be a solution. We could mount an engine to /.well-known/core with a routing helper (comparable to devise_for for example).
I naturally want to do rspec testing of my CoAP application.
It also speaks HTTP(S), although I imagine that production that it will be two completely different deploys.
I have changed things so that david is not automatically chosen for "rails server", so that I can develop in both worlds the same time. So one has to do something like: "bin/rails server david -b ::2 -p 5684"
rspec requests skip the framework layer and goes directly to routes. I can test my controllers via config/routes.rb just fine. But I can't test the resource discovery process, doing a GET to /.well-known/core?rt=est.ace to get the location of the resource and then using it.
I propose that the /.well-known/core processing no longer be special cased in lib/david/resource_discovery.rb's call, but instead be referenced in the applications' routes.rb.
The rails5 way might be to use a concern, I see that this how active-scaffold has gone, but the old rails4 "as_routes" may work as well for this.
The text was updated successfully, but these errors were encountered: