Skip to content

Commit a550fa1

Browse files
authored
Merge pull request #849 from govuk-one-login/OLH-4087-error
OLH-4087: Update authorize error page
2 parents 5a9d38b + b2f4c12 commit a550fa1

8 files changed

Lines changed: 17 additions & 12 deletions

File tree

solutions/frontend/src/journeys/utils/onRequest.test.ts

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ vi.mock(import("../../utils/paths.js"), () => ({
4242
},
4343
},
4444
others: {
45-
authorizeError: { path: "/authorize-error" },
45+
authorizeError: { path: "/error" },
4646
},
4747
},
4848
}));
@@ -188,7 +188,7 @@ describe("onRequest", () => {
188188
"Count",
189189
1,
190190
);
191-
expect(mockReply.redirect).toHaveBeenCalledWith("/authorize-error");
191+
expect(mockReply.redirect).toHaveBeenCalledWith("/error");
192192
});
193193
});
194194

@@ -216,7 +216,7 @@ describe("onRequest", () => {
216216
"Count",
217217
1,
218218
);
219-
expect(mockReply.redirect).toHaveBeenCalledWith("/authorize-error");
219+
expect(mockReply.redirect).toHaveBeenCalledWith("/error");
220220
});
221221
});
222222

@@ -250,7 +250,7 @@ describe("onRequest", () => {
250250
"Count",
251251
1,
252252
);
253-
expect(mockReply.redirect).toHaveBeenCalledWith("/authorize-error");
253+
expect(mockReply.redirect).toHaveBeenCalledWith("/error");
254254
});
255255
});
256256

@@ -305,7 +305,7 @@ describe("onRequest", () => {
305305
// Test with a path that has no analytics in the mock
306306
mockReply.globals = {
307307
currentUrl: {
308-
pathname: "/authorize-error",
308+
pathname: "/error",
309309
} as URL,
310310
};
311311

solutions/frontend/src/templates/layout/base.njk

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,6 @@
2727
{% endif -%}
2828
{{ 'general.serviceNameTitle' | translate if not hideTitleProductName}}
2929
{%- endblock %}
30-
3130
{% block bodyStart %}
3231
{% include 'templates/layout/cookieBanner.njk' %}
3332
{% endblock %}

solutions/frontend/src/translations/cy.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -35,8 +35,8 @@
3535
"buttonText": "Ewch i hafan GOV.UK"
3636
},
3737
"error500": {
38-
"title": "Maen ddrwg gennym, mae problem gyda’r gwasanaeth",
39-
"header": "Maen ddrwg gennym, mae problem gyda’r gwasanaeth",
38+
"title": "Mae'n ddrwg gennym, mae problem",
39+
"header": "Mae'n ddrwg gennym, mae problem",
4040
"content": {
4141
"paragraph1": "Rhowch gynnig arall yn nes ymlaen."
4242
}

solutions/frontend/src/translations/en.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -35,8 +35,8 @@
3535
"buttonText": "Go to the GOV.UK homepage"
3636
},
3737
"error500": {
38-
"title": "Sorry, there is a problem with the service",
39-
"header": "Sorry, there is a problem with the service",
38+
"title": "Sorry, there is a problem",
39+
"header": "Sorry, there is a problem",
4040
"content": {
4141
"paragraph1": "Try again later."
4242
}

solutions/frontend/src/utils/paths.ts

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -101,7 +101,13 @@ export const paths = {
101101
},
102102
others: {
103103
authorize: { path: "/authorize" },
104-
authorizeError: { path: "/authorize-error" },
104+
authorizeError: {
105+
path: "/error",
106+
analytics: {
107+
...analyticsDefaults,
108+
contentId: "a1a3dddd-9e65-40dc-9256-12ed597ec40e",
109+
},
110+
},
105111
},
106112
} as const satisfies {
107113
journeys: {
Loading
Loading

solutions/integration-tests/tests/steps/shared.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ const stubsUrl = getStubsUrl();
1414
export const pageNameToPath: Record<string, string> = {
1515
"Non-existent page": "/non-existent-page",
1616
Healthcheck: "/healthcheck",
17-
"Authorize error": "/authorize-error",
17+
"Authorize error": "/error",
1818
"Testing journey - step 1": "/testing-journey/step-1",
1919
"Testing journey - enter password": "/testing-journey/enter-password",
2020
"Testing journey - confirmation": "/testing-journey/confirm",

0 commit comments

Comments
 (0)