From eb8f640235e7c91380adcc7055461e5b4f6e40ab Mon Sep 17 00:00:00 2001 From: Tore Brede <Tore.Brede@uib.no> Date: Fri, 12 Nov 2021 12:55:21 +0100 Subject: [PATCH] Adding a filter to fix failing test --- frontend/src/routes/guest/register/registerPage.tsx | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/frontend/src/routes/guest/register/registerPage.tsx b/frontend/src/routes/guest/register/registerPage.tsx index 71e6437c..fbb45348 100644 --- a/frontend/src/routes/guest/register/registerPage.tsx +++ b/frontend/src/routes/guest/register/registerPage.tsx @@ -298,6 +298,13 @@ const GuestRegisterStep = forwardRef( ] return countryTuple }) + .filter( + (countryTuple: [string, string]) => + // All countries are expected to have a name, this filtering + // is here to make some tests run in an environment where the + // internationalization is not set up + countryTuple[1] !== undefined + ) .sort( ( countryTuple1: [string, string], -- GitLab