From 3bf316dbd9b4c555ef9b21f43d56c7d7309766d7 Mon Sep 17 00:00:00 2001 From: Dmitriy Zaporozhets Date: Thu, 25 Sep 2014 16:10:03 +0300 Subject: [PATCH] Fix security tests Signed-off-by: Dmitriy Zaporozhets --- spec/features/security/project/internal_access_spec.rb | 2 +- spec/features/security/project/private_access_spec.rb | 2 +- spec/features/security/project/public_access_spec.rb | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/spec/features/security/project/internal_access_spec.rb b/spec/features/security/project/internal_access_spec.rb index f86b3db32eb..598d554a946 100644 --- a/spec/features/security/project/internal_access_spec.rb +++ b/spec/features/security/project/internal_access_spec.rb @@ -90,7 +90,7 @@ describe "Internal Project Access", feature: true do describe "GET /:project_path/blob" do before do commit = project.repository.commit - path = commit.tree.contents.select { |i| i.is_a?(Grit::Blob) }.first.name + path = '.gitignore' @blob_path = project_blob_path(project, File.join(commit.id, path)) end diff --git a/spec/features/security/project/private_access_spec.rb b/spec/features/security/project/private_access_spec.rb index a27361f4d15..b1d4c79e05b 100644 --- a/spec/features/security/project/private_access_spec.rb +++ b/spec/features/security/project/private_access_spec.rb @@ -90,7 +90,7 @@ describe "Private Project Access", feature: true do describe "GET /:project_path/blob" do before do commit = project.repository.commit - path = commit.tree.contents.select { |i| i.is_a?(Grit::Blob) }.first.name + path = '.gitignore' @blob_path = project_blob_path(project, File.join(commit.id, path)) end diff --git a/spec/features/security/project/public_access_spec.rb b/spec/features/security/project/public_access_spec.rb index f114965bd4a..a4c8a2be25a 100644 --- a/spec/features/security/project/public_access_spec.rb +++ b/spec/features/security/project/public_access_spec.rb @@ -95,7 +95,7 @@ describe "Public Project Access", feature: true do describe "GET /:project_path/blob" do before do commit = project.repository.commit - path = commit.tree.contents.select { |i| i.is_a?(Grit::Blob) }.first.name + path = '.gitignore' @blob_path = project_blob_path(project, File.join(commit.id, path)) end