From fb10060d9c4d7d18b5f985cca2e97b4482998ed9 Mon Sep 17 00:00:00 2001 From: Alex Date: Mon, 27 Jul 2020 16:40:23 +0100 Subject: [PATCH 1/2] Allow requests for all domains e.g. .dev.gov.uk --- spec/dummy/config/environments/development.rb | 3 +++ 1 file changed, 3 insertions(+) diff --git a/spec/dummy/config/environments/development.rb b/spec/dummy/config/environments/development.rb index 35c551f615..450e98e5b2 100644 --- a/spec/dummy/config/environments/development.rb +++ b/spec/dummy/config/environments/development.rb @@ -12,6 +12,9 @@ # Show full error reports. config.consider_all_requests_local = true + # Allow requests for all domains e.g. .dev.gov.uk + config.hosts.clear + # Enable/disable caching. By default caching is disabled. if Rails.root.join("tmp/caching-dev.txt").exist? config.action_controller.perform_caching = true From 771eab68fad85fd2cb56c0d0fc46be7d3c1fe693 Mon Sep 17 00:00:00 2001 From: Alex Date: Wed, 29 Jul 2020 20:05:57 +0100 Subject: [PATCH 2/2] Fix test by ensuring we compare same types --- .../presenters/machine_readable/html_publication_schema_spec.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/spec/lib/govuk_publishing_components/presenters/machine_readable/html_publication_schema_spec.rb b/spec/lib/govuk_publishing_components/presenters/machine_readable/html_publication_schema_spec.rb index e1419372d3..751e467613 100644 --- a/spec/lib/govuk_publishing_components/presenters/machine_readable/html_publication_schema_spec.rb +++ b/spec/lib/govuk_publishing_components/presenters/machine_readable/html_publication_schema_spec.rb @@ -30,7 +30,7 @@ it "behaves like an article" do expect(structured_data["@type"]).to eql("Article") - expect(structured_data["articleBody"]).to eq(page.body) + expect(structured_data["articleBody"].to_s).to eq(page.body) end context "when one heading present" do