Skip to content

Commit 76a9c44

Browse files
committed
Update specs for header component
In GOV.UK Component for Ruby on Rails 6.0.0 the class for the homepage link in the header was changed [[1]], to match the same change in GOV.UK Frontend 6.0.0 [[2]]. This commit updates our specs to use the new class, as they were relying on it to be able to pick out and test the homepage link. [1]: x-govuk/govuk-components@255e51e [2]: alphagov/govuk-frontend@9f4728d
1 parent f12f95c commit 76a9c44

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

spec/components/form_header_component/view_spec.rb

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@
1515
it "links to the GOV.UK homepage" do
1616
render_inline(described_class.new(current_context:, mode:))
1717

18-
expect(page.find("a.govuk-header__link--homepage")[:href]).to eq "https://www.gov.uk/"
18+
expect(page.find("a.govuk-header__homepage-link")[:href]).to eq "https://www.gov.uk/"
1919
end
2020

2121
it "links to the form start page" do
@@ -55,7 +55,7 @@
5555

5656
render_inline(described_class.new(current_context:, mode:))
5757

58-
expect(page.find(".govuk-header__link--homepage")[:href]).to eq "http://forms-admin/"
58+
expect(page.find(".govuk-header__homepage-link")[:href]).to eq "http://forms-admin/"
5959
end
6060
end
6161

@@ -75,7 +75,7 @@
7575

7676
render_inline(described_class.new(current_context:, mode:))
7777

78-
expect(page.find(".govuk-header__link--homepage")[:href]).to eq "http://forms-admin/"
78+
expect(page.find(".govuk-header__homepage-link")[:href]).to eq "http://forms-admin/"
7979
end
8080
end
8181

0 commit comments

Comments
 (0)