Commit 1e3f09b2 authored by Dmitriy Zaporozhets's avatar Dmitriy Zaporozhets

Fix tests

parent 128ef337
...@@ -3,7 +3,7 @@ require 'spec_helper' ...@@ -3,7 +3,7 @@ require 'spec_helper'
describe Projects::CommitController do describe Projects::CommitController do
let(:project) { create(:project_with_code) } let(:project) { create(:project_with_code) }
let(:user) { create(:user) } let(:user) { create(:user) }
let(:commit) { project.repository.last_commit_for("master") } let(:commit) { project.repository.commit("master") }
before do before do
sign_in(user) sign_in(user)
......
...@@ -175,8 +175,8 @@ describe "Application access" do ...@@ -175,8 +175,8 @@ describe "Application access" do
it { should be_denied_for :visitor } it { should be_denied_for :visitor }
end end
describe "GET /project_code/repository" do describe "GET /project_code/branches/recent" do
subject { project_repository_path(project) } subject { recent_project_branches_path(project) }
it { should be_allowed_for master } it { should be_allowed_for master }
it { should be_allowed_for reporter } it { should be_allowed_for reporter }
...@@ -186,7 +186,7 @@ describe "Application access" do ...@@ -186,7 +186,7 @@ describe "Application access" do
it { should be_denied_for :visitor } it { should be_denied_for :visitor }
end end
describe "GET /project_code/repository/branches" do describe "GET /project_code/branches" do
subject { project_branches_path(project) } subject { project_branches_path(project) }
before do before do
...@@ -202,7 +202,7 @@ describe "Application access" do ...@@ -202,7 +202,7 @@ describe "Application access" do
it { should be_denied_for :visitor } it { should be_denied_for :visitor }
end end
describe "GET /project_code/repository/tags" do describe "GET /project_code/tags" do
subject { project_tags_path(project) } subject { project_tags_path(project) }
before do before do
...@@ -417,8 +417,8 @@ describe "Application access" do ...@@ -417,8 +417,8 @@ describe "Application access" do
it { should be_denied_for :visitor } it { should be_denied_for :visitor }
end end
describe "GET /project_code/repository" do describe "GET /project_code/branches/recent" do
subject { project_repository_path(project) } subject { recent_project_branches_path(project) }
it { should be_allowed_for master } it { should be_allowed_for master }
it { should be_allowed_for reporter } it { should be_allowed_for reporter }
...@@ -428,7 +428,7 @@ describe "Application access" do ...@@ -428,7 +428,7 @@ describe "Application access" do
it { should be_denied_for :visitor } it { should be_denied_for :visitor }
end end
describe "GET /project_code/repository/branches" do describe "GET /project_code/branches" do
subject { project_branches_path(project) } subject { project_branches_path(project) }
before do before do
...@@ -444,7 +444,7 @@ describe "Application access" do ...@@ -444,7 +444,7 @@ describe "Application access" do
it { should be_denied_for :visitor } it { should be_denied_for :visitor }
end end
describe "GET /project_code/repository/tags" do describe "GET /project_code/tags" do
subject { project_tags_path(project) } subject { project_tags_path(project) }
before do before do
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment