From fe13f110412d85c05dc68e5ee1db499f681bf722 Mon Sep 17 00:00:00 2001 From: Douwe Maan Date: Thu, 29 Jun 2017 12:06:35 -0500 Subject: Create and use project path helpers that only need a project, no namespace --- spec/views/ci/status/_badge.html.haml_spec.rb | 3 +-- spec/views/projects/merge_requests/_commits.html.haml_spec.rb | 5 +---- 2 files changed, 2 insertions(+), 6 deletions(-) (limited to 'spec/views') diff --git a/spec/views/ci/status/_badge.html.haml_spec.rb b/spec/views/ci/status/_badge.html.haml_spec.rb index 72323da2838..6a4738ba443 100644 --- a/spec/views/ci/status/_badge.html.haml_spec.rb +++ b/spec/views/ci/status/_badge.html.haml_spec.rb @@ -16,8 +16,7 @@ describe 'ci/status/_badge', :view do end it 'has link to build details page' do - details_path = namespace_project_job_path( - project.namespace, project, build) + details_path = project_job_path(project, build) render_status(build) diff --git a/spec/views/projects/merge_requests/_commits.html.haml_spec.rb b/spec/views/projects/merge_requests/_commits.html.haml_spec.rb index 3e17fe2104b..98c7de9b709 100644 --- a/spec/views/projects/merge_requests/_commits.html.haml_spec.rb +++ b/spec/views/projects/merge_requests/_commits.html.haml_spec.rb @@ -25,10 +25,7 @@ describe 'projects/merge_requests/_commits.html.haml' do render commit = source_project.commit(merge_request.source_branch) - href = namespace_project_commit_path( - source_project.namespace, - source_project, - commit) + href = project_commit_path(source_project, commit) expect(rendered).to have_link(Commit.truncate_sha(commit.sha), href: href) end -- cgit v1.2.3