fixing namespace controller resource spec
This commit is contained in:
parent
2160183e86
commit
092b510a2f
|
@ -37,11 +37,10 @@ describe CanCan::ControllerResource do
|
||||||
module MyEngine
|
module MyEngine
|
||||||
class Project < ::Project; end
|
class Project < ::Project; end
|
||||||
end
|
end
|
||||||
|
|
||||||
project = MyEngine::Project.create!
|
project = MyEngine::Project.create!
|
||||||
@params.merge!(:controller => "MyEngine::ProjectsController", :action => "show", :id => project.id)
|
@params.merge!(:controller => "MyEngine::ProjectsController", :action => "show", :id => project.id)
|
||||||
resource = CanCan::ControllerResource.new(@controller)
|
resource = CanCan::ControllerResource.new(@controller, :load => true)
|
||||||
resource.load_resource
|
resource.process
|
||||||
@controller.instance_variable_get(:@project).should == project
|
@controller.instance_variable_get(:@project).should == project
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue
Block a user