From e6f63164faef7ef4b0bc0ebb9d135a3b5f3b4d64 Mon Sep 17 00:00:00 2001 From: natdeanlewissoftwire Date: Tue, 23 Jan 2024 17:29:38 +0000 Subject: [PATCH] feat: update tests and underline css --- app/views/home/index.html.erb | 4 +--- app/views/start/index.html.erb | 2 +- spec/requests/start_controller_spec.rb | 17 +++++++++++++++-- 3 files changed, 17 insertions(+), 6 deletions(-) diff --git a/app/views/home/index.html.erb b/app/views/home/index.html.erb index 0aacbdc16..852cbda93 100644 --- a/app/views/home/index.html.erb +++ b/app/views/home/index.html.erb @@ -48,9 +48,7 @@
<%= render partial: "layouts/collection_resources" %> -
-
-
+
<%= render partial: "home/upcoming_deadlines" %>
<%= render partial: "layouts/about_this_service" %> diff --git a/app/views/start/index.html.erb b/app/views/start/index.html.erb index b885ef717..14ed39282 100644 --- a/app/views/start/index.html.erb +++ b/app/views/start/index.html.erb @@ -25,7 +25,7 @@

<%= govuk_link_to guidance_path do %>Guidance for submitting social housing lettings and sales data (CORE)<% end %>


<%= render partial: "layouts/collection_resources" %> -
+
<%= render partial: "layouts/about_this_service" %>
diff --git a/spec/requests/start_controller_spec.rb b/spec/requests/start_controller_spec.rb index ad1d04b3d..d6e30ae09 100644 --- a/spec/requests/start_controller_spec.rb +++ b/spec/requests/start_controller_spec.rb @@ -37,10 +37,17 @@ RSpec.describe StartController, type: :request do allow(Time).to receive(:now).and_return(Time.zone.local(2024, 1, 1)) end - it "displays correct resources for 2022/23 and 2023/24 collection years" do + it "displays correct resources for 2023/24 and 2024/25 collection years" do get "/", headers: headers, params: {} + expect(page).to have_content("Lettings 24/25") expect(page).to have_content("Lettings 23/24") + expect(page).to have_content("Lettings 2024 to 2025") + expect(page).to have_content("Lettings 2023 to 2024") + expect(page).to have_content("Sales 24/25") expect(page).to have_content("Sales 23/24") + expect(page).to have_content("Sales 2024 to 2025") + expect(page).to have_content("Sales 2023 to 2024") + end end @@ -49,10 +56,16 @@ RSpec.describe StartController, type: :request do allow(Time).to receive(:now).and_return(Time.zone.local(2025, 1, 1)) end - it "displays correct resources for 2022/23 and 2023/24 collection years" do + it "displays correct resources for 2023/24 and 2024/25 collection years" do get "/", headers: headers, params: {} + expect(page).to have_content("Lettings 24/25") expect(page).not_to have_content("Lettings 23/24") + expect(page).to have_content("Lettings 2024 to 2025") + expect(page).not_to have_content("Lettings 2023 to 2024") + expect(page).to have_content("Sales 24/25") expect(page).not_to have_content("Sales 23/24") + expect(page).to have_content("Sales 2024 to 2025") + expect(page).not_to have_content("Sales 2023 to 2024") end end