diff --git a/locales/cy/translations.json b/locales/cy/translations.json index 4b1a284..a76a203 100644 --- a/locales/cy/translations.json +++ b/locales/cy/translations.json @@ -1,4 +1,9 @@ { + "buttons" : { + "continue" : "WELSH - Continue", + "saveAndContinue" : "WELSH - Save and continue" + }, + "emailPage" : { "whatIsEmail" : "WELSH - What is the registered email address for the partnership?", "emailHint" : "WELSH - Partners must be able to access emails that are sent to this address.", @@ -9,6 +14,24 @@ } }, + "errorPage" : { + "title" : "WELSH - Sorry, the service is unavailable", + "tryLater" : "WELSH - You will be able to use the service at a later date.", + "moreInfo" : "WELSH - Email enquiries@companieshouse.gov.uk, if you need more information." + }, + + "generalPartnerChoicePage": { + "title": "WELSH - You now need to tell us about the general partners", + "hint": "WELSH - You can add more later.", + "person": "WELSH - A person", + "legalEntity": "WELSH - A legal entity" + }, + + "generalPartnersPage": { + "title": "WELSH - You now need to tell us about the general partners", + "pageInformation": "WELSH - If the partnership has more than one general partner, you'll add them one at a time." + }, + "limitedPartnerChoicePage" : { "isPersonOrLegalEntity" : "WELSH - Is the limited partner a person or a legal entity?", "isPersonOrLegalEntityHint" : "WELSH - You can add more later.", @@ -16,6 +39,11 @@ "legalEntity" : "WELSH - A legal entity" }, + "limitedPartnersPage": { + "title": "WELSH - You now need to tell us about the limited partners", + "pageInformation": "WELSH - If the partnership has more than one limited partner, you'll add them one at a time." + }, + "namePage" : { "title" : "WELSH - Limited partnership name", "whatIsName" : "WELSH - What is the limited partnership name?", @@ -44,6 +72,16 @@ } }, + "pageNotFound" : { + "title" : "WELSH - Page Not Found", + "spelling" : "WELSH - If you typed the web address, check it is spelled correctly.", + "copiedAddress" : "WELSH - If you pasted the web address, check you copied the entire address.", + "movedPage" : "WELSH - If the web address is correct or you selected a link, the page may have moved.", + "goToStartPage" : "WELSH - To register a limited partnership, go to the Register a limited partnership start page." + }, + + "service" : "WELSH - Register a Limited Partnership", + "startPage" : { "title" : "Partneriaethau Cyfyngedig yw hyn", "errorStartAddressMissing" : "Rhowch gyfeiriad" @@ -58,41 +96,5 @@ "SPFLP": "WELSH - Private fund limited partnership in Scotland", "SQP": "WELSH - Scottish qualifying partnership" } - }, - - "generalPartnersPage": { - "title": "WELSH - You now need to tell us about the general partners", - "pageInformation": "WELSH - If the partnership has more than one general partner, you'll add them one at a time." - }, - - "limitedPartnersPage": { - "title": "WELSH - You now need to tell us about the limited partners", - "pageInformation": "WELSH - If the partnership has more than one limited partner, you'll add them one at a time." - }, - - "generalPartnerChoicePage": { - "title": "WELSH - You now need to tell us about the general partners", - "hint": "WELSH - You can add more later.", - "person": "WELSH - A person", - "legalEntity": "WELSH - A legal entity" - }, - - "pageNotFound" : { - "title" : "WELSH - Page Not Found", - "spelling" : "WELSH - If you typed the web address, check it is spelled correctly.", - "copiedAddress" : "WELSH - If you pasted the web address, check you copied the entire address.", - "movedPage" : "WELSH - If the web address is correct or you selected a link, the page may have moved.", - "goToStartPage" : "WELSH - To register a limited partnership, go to the Register a limited partnership start page." - }, - - "errorPage" : { - "title" : "WELSH - Sorry, the service is unavailable", - "tryLater" : "WELSH - You will be able to use the service at a later date.", - "moreInfo" : "WELSH - Email enquiries@companieshouse.gov.uk, if you need more information." - }, - - "buttons" : { - "continue" : "WELSH - Continue", - "saveAndContinue" : "WELSH - Save and continue" - } + } } diff --git a/locales/en/translations.json b/locales/en/translations.json index f10c3f0..fc149be 100644 --- a/locales/en/translations.json +++ b/locales/en/translations.json @@ -1,4 +1,9 @@ { + "buttons" : { + "continue" : "Continue", + "saveAndContinue" : "Save and continue" + }, + "emailPage" : { "whatIsEmail" : "What is the registered email address for the partnership?", "emailHint" : "Partners must be able to access emails that are sent to this address.", @@ -9,6 +14,24 @@ } }, + "errorPage" : { + "title" : "Sorry, the service is unavailable", + "tryLater" : "You will be able to use the service at a later date.", + "moreInfo" : "Email enquiries@companieshouse.gov.uk, if you need more information." + }, + + "generalPartnerChoicePage": { + "title": "Is the general partner a person or a legal entity?", + "hint": "You can add more later.", + "person": "A person", + "legalEntity": "A legal entity" + }, + + "generalPartnersPage": { + "title": "You now need to tell us about the general partners", + "pageInformation": "If the partnership has more than one general partner, you'll add them one at a time." + }, + "limitedPartnerChoicePage" : { "isPersonOrLegalEntity" : "Is the limited partner a person or a legal entity?", "isPersonOrLegalEntityHint" : "You can add more later.", @@ -16,6 +39,11 @@ "legalEntity" : "A legal entity" }, + "limitedPartnersPage": { + "title": "You now need to tell us about the limited partners", + "pageInformation": "If the partnership has more than one limited partner, you'll add them one at a time." + }, + "namePage" : { "title" : "Limited partnership name", "whatIsName" : "What is the limited partnership name?", @@ -44,6 +72,16 @@ } }, + "pageNotFound" : { + "title" : "Page not found", + "spelling" : "If you typed the web address, check it is spelled correctly.", + "copiedAddress" : "If you pasted the web address, check you copied the entire address.", + "movedPage" : "If the web address is correct or you selected a link, the page may have moved.", + "goToStartPage" : "To register a limited partnership, go to the Register a limited partnership start page." + }, + + "service" : "Register a Limited Partnership", + "startPage" : { "title" : "This is Limited Partnerships", "errorStartAddressMissing" : "Please enter an address" @@ -58,41 +96,5 @@ "SPFLP": "Private fund limited partnership in Scotland", "SQP": "Scottish qualifying partnership" } - }, - - "generalPartnersPage": { - "title": "You now need to tell us about the general partners", - "pageInformation": "If the partnership has more than one general partner, you'll add them one at a time." - }, - - "limitedPartnersPage": { - "title": "You now need to tell us about the limited partners", - "pageInformation": "If the partnership has more than one limited partner, you'll add them one at a time." - }, - - "generalPartnerChoicePage": { - "title": "Is the general partner a person or a legal entity?", - "hint": "You can add more later.", - "person": "A person", - "legalEntity": "A legal entity" - }, - - "pageNotFound" : { - "title" : "Page not found", - "spelling" : "If you typed the web address, check it is spelled correctly.", - "copiedAddress" : "If you pasted the web address, check you copied the entire address.", - "movedPage" : "If the web address is correct or you selected a link, the page may have moved.", - "goToStartPage" : "To register a limited partnership, go to the Register a limited partnership start page." - }, - - "errorPage" : { - "title" : "Sorry, the service is unavailable", - "tryLater" : "You will be able to use the service at a later date.", - "moreInfo" : "Email enquiries@companieshouse.gov.uk, if you need more information." - }, - - "buttons" : { - "continue" : "Continue", - "saveAndContinue" : "Save and continue" } } diff --git a/src/presentation/test/integration/registration/email.test.ts b/src/presentation/test/integration/registration/email.test.ts index 42a75c6..8709fc8 100644 --- a/src/presentation/test/integration/registration/email.test.ts +++ b/src/presentation/test/integration/registration/email.test.ts @@ -25,6 +25,9 @@ describe("Email Page", () => { const res = await request(app).get(EMAIL_URL + "?lang=en"); expect(res.status).toBe(200); + expect(res.text).toContain( + `${enTranslationText.emailPage.emailUsedFor.title} - ${enTranslationText.service} - GOV.UK` + ); expect(res.text).toContain(enTranslationText.emailPage.whatIsEmail); expect(res.text).toContain(enTranslationText.emailPage.emailHint); expect(res.text).toContain(enTranslationText.buttons.saveAndContinue); @@ -36,6 +39,9 @@ describe("Email Page", () => { const res = await request(app).get(EMAIL_URL + "?lang=cy"); expect(res.status).toBe(200); + expect(res.text).toContain( + `${cyTranslationText.emailPage.emailUsedFor.title} - ${cyTranslationText.service} - GOV.UK` + ); expect(res.text).toContain(cyTranslationText.emailPage.whatIsEmail); expect(res.text).toContain(cyTranslationText.emailPage.emailHint); expect(res.text).toContain(cyTranslationText.buttons.saveAndContinue); diff --git a/src/presentation/test/integration/registration/general-partner-choice.test.ts b/src/presentation/test/integration/registration/general-partner-choice.test.ts index eb23cd3..e9f75f3 100644 --- a/src/presentation/test/integration/registration/general-partner-choice.test.ts +++ b/src/presentation/test/integration/registration/general-partner-choice.test.ts @@ -34,6 +34,9 @@ describe("General Partner Choice Page", () => { const res = await request(app).get(GENERAL_PARTNER_CHOICE_URL + "?lang=cy"); expect(res.status).toBe(200); + expect(res.text).toContain( + `${cyTranslationText.generalPartnerChoicePage.title } - ${cyTranslationText.service} - GOV.UK` + ); expect(res.text).toContain( cyTranslationText.generalPartnerChoicePage.title ); @@ -44,6 +47,9 @@ describe("General Partner Choice Page", () => { const res = await request(app).get(GENERAL_PARTNER_CHOICE_URL + "?lang=en"); expect(res.status).toBe(200); + expect(res.text).toContain( + `${enTranslationText.generalPartnerChoicePage.title} - ${enTranslationText.service} - GOV.UK` + ); expect(res.text).toContain( enTranslationText.generalPartnerChoicePage.title ); diff --git a/src/presentation/test/integration/registration/general-partners.test.ts b/src/presentation/test/integration/registration/general-partners.test.ts index cec8dc1..cbe00b4 100644 --- a/src/presentation/test/integration/registration/general-partners.test.ts +++ b/src/presentation/test/integration/registration/general-partners.test.ts @@ -23,6 +23,9 @@ describe("General Partners Page", () => { const res = await request(app).get(GENERAL_PARTNERS_URL + "?lang=cy"); expect(res.status).toBe(200); + expect(res.text).toContain( + `${cyTranslationText.generalPartnersPage.title } - ${cyTranslationText.service} - GOV.UK` + ); expect(res.text).toContain(cyTranslationText.generalPartnersPage.title); }); @@ -31,6 +34,9 @@ describe("General Partners Page", () => { const res = await request(app).get(GENERAL_PARTNERS_URL + "?lang=en"); expect(res.status).toBe(200); + expect(res.text).toContain( + `${enTranslationText.generalPartnersPage.title } - ${enTranslationText.service} - GOV.UK` + ); expect(res.text).toContain(enTranslationText.generalPartnersPage.title); }); }); diff --git a/src/presentation/test/integration/registration/limited-partner-choice.test.ts b/src/presentation/test/integration/registration/limited-partner-choice.test.ts index 69b4d31..6ff2c7a 100644 --- a/src/presentation/test/integration/registration/limited-partner-choice.test.ts +++ b/src/presentation/test/integration/registration/limited-partner-choice.test.ts @@ -36,6 +36,9 @@ describe("Limited Partner Choice Page", () => { const res = await request(app).get(LIMITED_PARTNER_CHOICE_URL + "?lang=cy"); expect(res.status).toBe(200); + expect(res.text).toContain( + `${cyTranslationText.limitedPartnerChoicePage.isPersonOrLegalEntity} - ${cyTranslationText.service} - GOV.UK` + ); expect(res.text).toContain( cyTranslationText.limitedPartnerChoicePage.isPersonOrLegalEntity ); @@ -46,6 +49,9 @@ describe("Limited Partner Choice Page", () => { const res = await request(app).get(LIMITED_PARTNER_CHOICE_URL + "?lang=en"); expect(res.status).toBe(200); + expect(res.text).toContain( + `${enTranslationText.limitedPartnerChoicePage.isPersonOrLegalEntity} - ${enTranslationText.service} - GOV.UK` + ); expect(res.text).toContain( enTranslationText.limitedPartnerChoicePage.isPersonOrLegalEntity ); diff --git a/src/presentation/test/integration/registration/limited-partners.test.ts b/src/presentation/test/integration/registration/limited-partners.test.ts index 23da1b3..e2ad559 100644 --- a/src/presentation/test/integration/registration/limited-partners.test.ts +++ b/src/presentation/test/integration/registration/limited-partners.test.ts @@ -23,6 +23,9 @@ describe("Limited Partners Page", () => { const res = await request(app).get(LIMITED_PARTNERS_URL + "?lang=cy"); expect(res.status).toBe(200); + expect(res.text).toContain( + `${cyTranslationText.limitedPartnersPage.title} - ${cyTranslationText.service} - GOV.UK` + ); expect(res.text).toContain(cyTranslationText.limitedPartnersPage.title); }); @@ -31,6 +34,9 @@ describe("Limited Partners Page", () => { const res = await request(app).get(LIMITED_PARTNERS_URL + "?lang=en"); expect(res.status).toBe(200); + expect(res.text).toContain( + `${enTranslationText.limitedPartnersPage.title} - ${enTranslationText.service} - GOV.UK` + ); expect(res.text).toContain(enTranslationText.limitedPartnersPage.title); }); }); diff --git a/src/presentation/test/integration/registration/name.test.ts b/src/presentation/test/integration/registration/name.test.ts index 09c79f5..ddd6f5a 100644 --- a/src/presentation/test/integration/registration/name.test.ts +++ b/src/presentation/test/integration/registration/name.test.ts @@ -37,6 +37,9 @@ describe("Name Page", () => { const res = await request(app).get(NAME_URL + "?lang=cy"); expect(res.status).toBe(200); + expect(res.text).toContain( + `${cyTranslationText.namePage.title} - ${cyTranslationText.service} - GOV.UK` + ); expect(res.text).toContain(cyTranslationText.namePage.title); expect(res.text).toContain(cyTranslationText.namePage.whatIsName); expect(res.text).toContain(cyTranslationText.namePage.nameEnding); @@ -54,6 +57,9 @@ describe("Name Page", () => { const res = await request(app).get(NAME_URL + "?lang=en"); expect(res.status).toBe(200); + expect(res.text).toContain( + `${enTranslationText.namePage.title} - ${enTranslationText.service} - GOV.UK` + ); expect(res.text).toContain(enTranslationText.namePage.title); expect(res.text).toContain(enTranslationText.namePage.whatIsName); expect(res.text).toContain(enTranslationText.namePage.nameEnding); @@ -72,6 +78,9 @@ describe("Name Page", () => { const res = await request(app).get(NAME_URL + "?lang=cy"); expect(res.status).toBe(200); + expect(res.text).toContain( + `${cyTranslationText.namePage.privateFund.title} - ${cyTranslationText.service} - GOV.UK` + ); expect(res.text).toContain(cyTranslationText.namePage.privateFund.title); expect(res.text).toContain( cyTranslationText.namePage.privateFund.nameEnding @@ -90,6 +99,9 @@ describe("Name Page", () => { const res = await request(app).get(NAME_URL + "?lang=en"); expect(res.status).toBe(200); + expect(res.text).toContain( + `${enTranslationText.namePage.privateFund.title} - ${enTranslationText.service} - GOV.UK` + ); expect(res.text).toContain(enTranslationText.namePage.privateFund.title); expect(res.text).toContain( enTranslationText.namePage.privateFund.nameEnding @@ -109,6 +121,9 @@ describe("Name Page", () => { const res = await request(app).get(NAME_URL + "?lang=cy"); expect(res.status).toBe(200); + expect(res.text).toContain( + `${cyTranslationText.namePage.scottish.title} - ${cyTranslationText.service} - GOV.UK` + ); expect(res.text).toContain(cyTranslationText.namePage.scottish.title); expect(res.text).toContain(cyTranslationText.namePage.scottish.nameEnding); expect(res.text).toContain(cyTranslationText.buttons.saveAndContinue); @@ -125,6 +140,9 @@ describe("Name Page", () => { const res = await request(app).get(NAME_URL + "?lang=en"); expect(res.status).toBe(200); + expect(res.text).toContain( + `${enTranslationText.namePage.scottish.title} - ${enTranslationText.service} - GOV.UK` + ); expect(res.text).toContain(enTranslationText.namePage.scottish.title); expect(res.text).toContain(enTranslationText.namePage.scottish.nameEnding); expect(res.text).toContain(enTranslationText.buttons.saveAndContinue); @@ -142,6 +160,9 @@ describe("Name Page", () => { const res = await request(app).get(NAME_URL + "?lang=cy"); expect(res.status).toBe(200); + expect(res.text).toContain( + `${cyTranslationText.namePage.privateFund.scottish.title} - ${cyTranslationText.service} - GOV.UK` + ); expect(res.text).toContain( cyTranslationText.namePage.privateFund.scottish.title ); @@ -160,6 +181,9 @@ describe("Name Page", () => { const res = await request(app).get(NAME_URL + "?lang=en"); expect(res.status).toBe(200); + expect(res.text).toContain( + `${enTranslationText.namePage.privateFund.scottish.title} - ${enTranslationText.service} - GOV.UK` + ); expect(res.text).toContain( enTranslationText.namePage.privateFund.scottish.title ); diff --git a/src/views/email.njk b/src/views/email.njk index 7f48f95..21be281 100644 --- a/src/views/email.njk +++ b/src/views/email.njk @@ -1,5 +1,7 @@ {% extends "layout.njk" %} +{% set pageTitle = i18n.emailPage.emailUsedFor.title %} + {% block content %}