Pull down the latest code from github as there are some fixes to the auto-reloading of rule files in dev mode.. Take a look at that code to see how lazy-reloading of rules only when they change can work.
Specifically this commit. https://github.com/stffn/declarative_authorization/commit/a5e6beac067e8339c73b76498a4fa817ba786ba6
On 2012-08-24 10:46, Bishma Stornelli wrote:
I'm trying to store roles and permissions in the database and it's working fine. The only problem I have is that I need to reload the server for changes to take effect.Is there a way to force Declarative Authorization to reload the authorization rules?I tried modifying Authorization::Engine.instance like this:def self.instance (dsl_file = nil)@@instance = new(dsl_file)endAnd it works but it reload rules on every request. I could accept that but when I'm testing with cucumber, I don't know why it doesn't work.My scenario start like this:Given I am authenticated as ""
And I am authorized to ""
When I visit the "" page
If I use at that point save_and_open_page I get the not authorized error. It works fine out of cucumber. Any thoughts?
You received this message because you are subscribed to the Google Groups "declarative_authorization" group.
To view this discussion on the web visit https://groups.google.com/d/msg/declarative_authorization/-/kTzqNYdasrsJ.
To post to this group, send email to declarative_...@googlegroups.com.
To unsubscribe from this group, send email to declarative_author...@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/declarative_authorization?hl=en.
To unsubscribe from this group, send email to declarative_authorization+unsub...@googlegroups.com.