A set of Jest unit tests, extracted from govuk-frontend, to ensure ports meet the same template tests.
npm install -d govuk-frontend-template-spec
See https://github.com/penx/govuk-frontend-react and search for govuk-frontend-template-spec
for more details.
If using the GitHub repository, the code is extracted from govuk-frontend by running npm run build
. This is then included in the bundle when publishing to npm.
govuk-frontend provides templates using nunjucks. I'm creating a set of React components that aim to have feature parity with govuk-frontend and wanted to extract the govuk-frontend unit tests to validate this. This may also be useful for ports of the templates to other languages.
Also see: