From 726913f9878b742ef85ed69995d2d9802cc14f9f Mon Sep 17 00:00:00 2001 From: Alexander Machehin Date: Tue, 23 Jul 2013 00:53:19 +0600 Subject: [PATCH] [#105] fix specs for anonymous access --- spec/controllers/api/v1/pull_requests_controller.rb | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/spec/controllers/api/v1/pull_requests_controller.rb b/spec/controllers/api/v1/pull_requests_controller.rb index fb77d6c68..b72a24ff2 100644 --- a/spec/controllers/api/v1/pull_requests_controller.rb +++ b/spec/controllers/api/v1/pull_requests_controller.rb @@ -142,17 +142,17 @@ describe Api::V1::PullRequestsController do end %w(commits files).each do |action| - it "can show pull request #{action} in project" do + it "can show pull request #{action} in project", :anonymous_access => true do get action, :project_id => @project.id, :id => @pull.serial_id, :format => :json response.should be_success end - it "should render right template for commits action" do + it "should render right template for commits action", :anonymous_access => true do get action, :project_id => @project.id, :id => @pull.serial_id, :format => :json response.should render_template("api/v1/pull_requests/#{action}") end - it "can't show pull request #{action} in hidden project" do + it "can't show pull request #{action} in hidden project", :anonymous_access => true do get action, :project_id => @hidden_project.id, :id => @hidden_pull.serial_id, :format => :json response.should_not be_success end