Commit 56d83999 authored by Brandon Labuschagne's avatar Brandon Labuschagne

Merge branch 'mrincon-runner-detail-breadcrumb-fix' into 'master'

Improve the runner details title and breadcrumb

See merge request gitlab-org/gitlab!57247
parents 02915df6 a56180a1
- add_page_specific_style 'page_bundles/ci_status'
= content_for :title do
%h3.project-title
Runner ##{@runner.id}
.float-right
- if @runner.instance_type?
%span.runner-state.runner-state-shared
Shared
- else
%span.runner-state.runner-state-specific
Specific
- page_title @runner.short_sha
- add_to_breadcrumbs _("Runners"), admin_runners_path
- breadcrumb_title "##{@runner.id}"
- add_to_breadcrumbs _('Runners'), admin_runners_path
- breadcrumb_title page_title
%h2.page-title
= sprintf(s_('Runners|Runner #%{runner_id}'), {runner_id: @runner.id})
- if @runner.instance_type?
.bs-callout.bs-callout-success
......
---
title: Add Runner ID as title in Runner details page
merge_request: 57247
author:
type: changed
......@@ -26554,6 +26554,9 @@ msgstr ""
msgid "Runners|Revision"
msgstr ""
msgid "Runners|Runner #%{runner_id}"
msgstr ""
msgid "Runners|Shared"
msgstr ""
......
......@@ -285,8 +285,16 @@ RSpec.describe "Admin Runners" do
end
describe 'runner page breadcrumbs' do
it 'contains the current runner’s short sha' do
expect(page.find('h2')).to have_content(runner.short_sha)
it 'contains the current runner token' do
page.within '[data-testid="breadcrumb-links"]' do
expect(page.find('h2')).to have_content(runner.short_sha)
end
end
end
describe 'runner page title' do
it 'contains the runner id' do
expect(find('.page-title')).to have_content("Runner ##{runner.id}")
end
end
......
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