Browse Source

added button to create a new scheme

pull/671/head
JG 3 years ago
parent
commit
b074863ab6
  1. 4
      app/views/schemes/index.html.erb
  2. 4
      spec/features/schemes_spec.rb

4
app/views/schemes/index.html.erb

@ -7,7 +7,9 @@
<h2 class="govuk-visually-hidden">Supported housing schemes</h2> <h2 class="govuk-visually-hidden">Supported housing schemes</h2>
<%= render SearchComponent.new(current_user:, search_label: "Search by scheme name, code or postcode", value: @searched) %> <%= render SearchComponent.new(current_user:, search_label: "Search by service name or code", value: @searched) %>
<%= govuk_button_link_to "Create a new supported housing scheme" %>
<hr class="govuk-section-break govuk-section-break--visible govuk-section-break--m"> <hr class="govuk-section-break govuk-section-break--visible govuk-section-break--m">

4
spec/features/schemes_spec.rb

@ -219,6 +219,10 @@ RSpec.describe "Schemes scheme Features" do
end end
context "when creating a new scheme" do context "when creating a new scheme" do
before do
click_link "Schemes", href: "/schemes"
end
it "displays the link to create a new scheme" do it "displays the link to create a new scheme" do
expect(page).to have_link("Create a new supported housing scheme") expect(page).to have_link("Create a new supported housing scheme")
end end

Loading…
Cancel
Save