diff --git a/tests/components/ChatContainer.test.tsx b/tests/components/ChatContainer.test.tsx
index f82f47561..b8df581d5 100644
--- a/tests/components/ChatContainer.test.tsx
+++ b/tests/components/ChatContainer.test.tsx
@@ -10,6 +10,7 @@ import {
} from 'fixtures/beneficiaire'
import { desListesDeDiffusion } from 'fixtures/listes-de-diffusion'
import { BaseBeneficiaire, BeneficiaireEtChat } from 'interfaces/beneficiaire'
+import { getConseillersDuJeuneClientSide } from 'services/beneficiaires.service'
import { getListesDeDiffusionClientSide } from 'services/listes-de-diffusion.service'
import { getMessageImportant } from 'services/messages.service'
import renderWithContexts from 'tests/renderWithContexts'
@@ -32,6 +33,7 @@ describe('', () => {
let beneficiairesChats: BeneficiaireEtChat[]
beforeEach(async () => {
+ ;(getConseillersDuJeuneClientSide as jest.Mock).mockResolvedValue([])
;(getListesDeDiffusionClientSide as jest.Mock).mockResolvedValue(
desListesDeDiffusion()
)
diff --git a/tests/components/ChatRoom.test.tsx b/tests/components/ChatRoom.test.tsx
index 689af564a..57e84d053 100644
--- a/tests/components/ChatRoom.test.tsx
+++ b/tests/components/ChatRoom.test.tsx
@@ -375,8 +375,7 @@ describe('', () => {
onAccesConversation={accederConversation}
onAccesListesDiffusion={() => {}}
onOuvertureMenu={() => {}}
- />,
- {}
+ />
))
})
})
@@ -394,7 +393,7 @@ describe('', () => {
it('affiche les alertes sur petit écran', () => {
expect(AlerteDisplayer).toHaveBeenCalledWith(
{ hideOnLargeScreen: true },
- {}
+ undefined
)
})
@@ -471,8 +470,7 @@ describe('', () => {
onAccesConversation={() => {}}
onAccesListesDiffusion={() => {}}
onOuvertureMenu={() => {}}
- />,
- {}
+ />
))
})
@@ -501,8 +499,7 @@ describe('', () => {
onAccesConversation={() => {}}
onAccesListesDiffusion={() => {}}
onOuvertureMenu={() => {}}
- />,
- {}
+ />
)
// When
diff --git a/tests/pages/CloturePage.server.test.tsx b/tests/pages/CloturePage.server.test.tsx
index d15908a93..cff0ef9c4 100644
--- a/tests/pages/CloturePage.server.test.tsx
+++ b/tests/pages/CloturePage.server.test.tsx
@@ -51,7 +51,7 @@ describe('CloturePage server side', () => {
}),
returnTo: '/mes-jeunes/edition-rdv?idRdv=1&redirectUrl=redirectUrl',
},
- {}
+ undefined
)
})
diff --git a/tests/pages/ClotureSessionPage.server.test.tsx b/tests/pages/ClotureSessionPage.server.test.tsx
index 8e05ebb7e..b9d734793 100644
--- a/tests/pages/ClotureSessionPage.server.test.tsx
+++ b/tests/pages/ClotureSessionPage.server.test.tsx
@@ -102,7 +102,7 @@ describe('Cloture Session server side', () => {
inscriptionsInitiales: inscriptionsInitiales,
returnTo: `/agenda/sessions/session-1?redirectUrl=redirectUrl`,
},
- {}
+ undefined
)
})
diff --git a/tests/pages/ConsentementCguPage.server.test.tsx b/tests/pages/ConsentementCguPage.server.test.tsx
index 9e9d4e7a8..56622be0e 100644
--- a/tests/pages/ConsentementCguPage.server.test.tsx
+++ b/tests/pages/ConsentementCguPage.server.test.tsx
@@ -34,7 +34,7 @@ describe('ConsentementCGUPage server side', () => {
expect(metadata).toEqual({ title: 'Consentement CGU' })
expect(ConsentementCguPage).toHaveBeenCalledWith(
{ returnTo: '/?onboarding=true' },
- {}
+ undefined
)
})
@@ -47,6 +47,9 @@ describe('ConsentementCGUPage server side', () => {
// Then
expect(metadata).toEqual({ title: 'Consentement CGU' })
- expect(ConsentementCguPage).toHaveBeenCalledWith({ returnTo: '/?' }, {})
+ expect(ConsentementCguPage).toHaveBeenCalledWith(
+ { returnTo: '/?' },
+ undefined
+ )
})
})
diff --git a/tests/pages/DetailActionPage.server.test.tsx b/tests/pages/DetailActionPage.server.test.tsx
index d6fe0d7fc..7f9e3727a 100644
--- a/tests/pages/DetailActionPage.server.test.tsx
+++ b/tests/pages/DetailActionPage.server.test.tsx
@@ -83,7 +83,7 @@ describe('ActionPage server side', () => {
lectureSeule: false,
from: 'beneficiaire',
},
- {}
+ undefined
)
})
@@ -123,7 +123,7 @@ describe('ActionPage server side', () => {
lectureSeule: false,
from: 'pilotage',
},
- {}
+ undefined
)
})
})
diff --git a/tests/pages/DetailDemarchePage.server.test.tsx b/tests/pages/DetailDemarchePage.server.test.tsx
index f590bc87f..afb4b021e 100644
--- a/tests/pages/DetailDemarchePage.server.test.tsx
+++ b/tests/pages/DetailDemarchePage.server.test.tsx
@@ -96,7 +96,7 @@ describe('DetailDemarchePage server side', () => {
demarche,
lectureSeule: false,
},
- {}
+ undefined
)
})
diff --git a/tests/pages/DetailsSessionPage.server.test.tsx b/tests/pages/DetailsSessionPage.server.test.tsx
index 660b85da4..026298922 100644
--- a/tests/pages/DetailsSessionPage.server.test.tsx
+++ b/tests/pages/DetailsSessionPage.server.test.tsx
@@ -132,7 +132,7 @@ describe('Détails Session Page Server', () => {
session: session,
returnTo: 'redirectUrl',
},
- {}
+ undefined
)
})
})
diff --git a/tests/pages/EditionListeDiffusionPage.server.test.tsx b/tests/pages/EditionListeDiffusionPage.server.test.tsx
index 9526057c6..9ad736286 100644
--- a/tests/pages/EditionListeDiffusionPage.server.test.tsx
+++ b/tests/pages/EditionListeDiffusionPage.server.test.tsx
@@ -40,7 +40,7 @@ describe('Page d’édition d’une liste de diffusion', () => {
{
returnTo: '/mes-jeunes/listes-de-diffusion',
},
- {}
+ undefined
)
})
@@ -73,7 +73,7 @@ describe('Page d’édition d’une liste de diffusion', () => {
liste: listeDeDiffusion,
returnTo: '/mes-jeunes/listes-de-diffusion',
},
- {}
+ undefined
)
})
})
diff --git a/tests/pages/EmargementRdvPage.server.test.tsx b/tests/pages/EmargementRdvPage.server.test.tsx
index 6de1ac9f6..15c6d10e6 100644
--- a/tests/pages/EmargementRdvPage.server.test.tsx
+++ b/tests/pages/EmargementRdvPage.server.test.tsx
@@ -72,7 +72,7 @@ describe('EmargementRdvPage server side', () => {
evenement: acAEmarger,
agence: 'Montastruc-la-Conseillère',
},
- {}
+ undefined
)
})
})
@@ -102,7 +102,7 @@ describe('EmargementRdvPage server side', () => {
evenement: sessionAEmarger,
agence: 'Montastruc-la-Conseillère',
},
- {}
+ undefined
)
})
})
diff --git a/tests/pages/EnvoiMessageGroupePage.server.test.tsx b/tests/pages/EnvoiMessageGroupePage.server.test.tsx
index db786b55d..40aa79b04 100644
--- a/tests/pages/EnvoiMessageGroupePage.server.test.tsx
+++ b/tests/pages/EnvoiMessageGroupePage.server.test.tsx
@@ -58,7 +58,7 @@ describe('EnvoiMessageGroupePage server side', () => {
listesDiffusion: listesDeDiffusion,
returnTo: 'http://localhost:3000/agenda',
},
- {}
+ undefined
)
})
@@ -83,7 +83,7 @@ describe('EnvoiMessageGroupePage server side', () => {
listesDiffusion: listesDeDiffusion,
returnTo: '/mes-jeunes',
},
- {}
+ undefined
)
})
})
diff --git a/tests/pages/EtablissementPage.server.test.tsx b/tests/pages/EtablissementPage.server.test.tsx
index fd3579da2..214994822 100644
--- a/tests/pages/EtablissementPage.server.test.tsx
+++ b/tests/pages/EtablissementPage.server.test.tsx
@@ -40,7 +40,7 @@ describe('EtablissementPage server side', () => {
// Then
- expect(EtablissementPage).toHaveBeenCalledWith({}, {})
+ expect(EtablissementPage).toHaveBeenCalledWith({}, undefined)
})
it('prépare la page en tant que MILO', async () => {
@@ -53,7 +53,7 @@ describe('EtablissementPage server side', () => {
// Then
- expect(EtablissementPage).toHaveBeenCalledWith({}, {})
+ expect(EtablissementPage).toHaveBeenCalledWith({}, undefined)
})
})
})
diff --git a/tests/pages/FavorisPage.server.test.tsx b/tests/pages/FavorisPage.server.test.tsx
index d2d5ef58e..a5d448346 100644
--- a/tests/pages/FavorisPage.server.test.tsx
+++ b/tests/pages/FavorisPage.server.test.tsx
@@ -59,7 +59,7 @@ describe('Favoris', () => {
recherches,
lectureSeule: false,
},
- {}
+ undefined
)
})
})
diff --git a/tests/pages/HistoriquePage.server.test.tsx b/tests/pages/HistoriquePage.server.test.tsx
index 7588b0dba..4c967e60b 100644
--- a/tests/pages/HistoriquePage.server.test.tsx
+++ b/tests/pages/HistoriquePage.server.test.tsx
@@ -88,7 +88,7 @@ describe('HistoriquePage server side', () => {
beneficiaire: detailBeneficiaire,
onglet: 'INFORMATIONS',
},
- {}
+ undefined
)
})
})
diff --git a/tests/pages/HomePage.server.test.tsx b/tests/pages/HomePage.server.test.tsx
index eaa8c26e1..667aaf575 100644
--- a/tests/pages/HomePage.server.test.tsx
+++ b/tests/pages/HomePage.server.test.tsx
@@ -83,7 +83,7 @@ describe('HomePage server side', () => {
afficherModaleOnboarding: false,
redirectUrl: '/mes-jeunes',
},
- {}
+ undefined
)
})
})
@@ -117,7 +117,7 @@ describe('HomePage server side', () => {
redirectUrl: '/agenda',
referentielAgences: uneListeDAgencesFranceTravail(),
},
- {}
+ undefined
)
})
})
@@ -150,7 +150,7 @@ describe('HomePage server side', () => {
redirectUrl: '/mes-jeunes',
referentielAgences: undefined,
},
- {}
+ undefined
)
})
})
@@ -184,7 +184,7 @@ describe('HomePage server side', () => {
redirectUrl: '/agenda',
referentielAgences: uneListeDAgencesFranceTravail(),
},
- {}
+ undefined
)
})
})
diff --git a/tests/pages/ListesDiffusionPage.server.test.tsx b/tests/pages/ListesDiffusionPage.server.test.tsx
index 8f3151e66..81b6c915b 100644
--- a/tests/pages/ListesDiffusionPage.server.test.tsx
+++ b/tests/pages/ListesDiffusionPage.server.test.tsx
@@ -37,7 +37,7 @@ describe('Page Listes de Diffusion', () => {
{
listesDiffusion: desListesDeDiffusion(),
},
- {}
+ undefined
)
})
})
diff --git a/tests/pages/LoginCEJPage.server.test.tsx b/tests/pages/LoginCEJPage.server.test.tsx
index 23f44e476..94e8b8b54 100644
--- a/tests/pages/LoginCEJPage.server.test.tsx
+++ b/tests/pages/LoginCEJPage.server.test.tsx
@@ -41,6 +41,6 @@ describe('LoginCEJPage server side', () => {
title:
"Connexion dans l'espace conseiller - Outil du Contrat d’Engagement Jeune",
})
- expect(LoginCEJPage).toHaveBeenCalledWith({}, {})
+ expect(LoginCEJPage).toHaveBeenCalledWith({}, undefined)
})
})
diff --git a/tests/pages/LoginHubPage.server.test.tsx b/tests/pages/LoginHubPage.server.test.tsx
index b5562b7d6..987e04692 100644
--- a/tests/pages/LoginHubPage.server.test.tsx
+++ b/tests/pages/LoginHubPage.server.test.tsx
@@ -41,6 +41,6 @@ describe('LoginPage server side', () => {
title:
'Sélection de l’espace de connexion - Outil du Contrat d’Engagement Jeune et du pass emploi',
})
- expect(LoginHubPage).toHaveBeenCalledWith({}, {})
+ expect(LoginHubPage).toHaveBeenCalledWith({}, undefined)
})
})
diff --git a/tests/pages/LoginPassEmploiPage.server.test.tsx b/tests/pages/LoginPassEmploiPage.server.test.tsx
index 138503658..628bc0587 100644
--- a/tests/pages/LoginPassEmploiPage.server.test.tsx
+++ b/tests/pages/LoginPassEmploiPage.server.test.tsx
@@ -44,7 +44,7 @@ describe('LoginPassEmploiPage server side', () => {
})
expect(LoginPassEmploiPage).toHaveBeenCalledWith(
{ ssoAvenirProEstActif: true },
- {}
+ undefined
)
})
})
diff --git a/tests/pages/LogoutPage.server.test.tsx b/tests/pages/LogoutPage.server.test.tsx
index 41362801b..78501ed7b 100644
--- a/tests/pages/LogoutPage.server.test.tsx
+++ b/tests/pages/LogoutPage.server.test.tsx
@@ -19,7 +19,7 @@ describe('LogoutPage server side', () => {
render(await Logout())
// Then
- expect(LogoutPage).toHaveBeenCalledWith({ callbackUrl: '/login/cej' }, {})
+ expect(LogoutPage).toHaveBeenCalledWith({ callbackUrl: '/login/cej' }, undefined)
})
})
@@ -36,7 +36,7 @@ describe('LogoutPage server side', () => {
// Then
expect(LogoutPage).toHaveBeenCalledWith(
{ callbackUrl: '/login/passemploi' },
- {}
+ undefined
)
})
})
diff --git a/tests/pages/ModificationActionPage.server.test.tsx b/tests/pages/ModificationActionPage.server.test.tsx
index d8447c347..cf0d705f0 100644
--- a/tests/pages/ModificationActionPage.server.test.tsx
+++ b/tests/pages/ModificationActionPage.server.test.tsx
@@ -74,7 +74,7 @@ describe('ModificationActionPage server side', () => {
'/mes-jeunes/beneficiaire-1/actions/id-action-1'
),
},
- {}
+ undefined
)
})
diff --git a/tests/pages/NouvelleActionPage.server.test.tsx b/tests/pages/NouvelleActionPage.server.test.tsx
index bbdec33b1..6724e51a7 100644
--- a/tests/pages/NouvelleActionPage.server.test.tsx
+++ b/tests/pages/NouvelleActionPage.server.test.tsx
@@ -88,7 +88,7 @@ describe('NouvelleActionPage server side', () => {
],
returnTo: '/mes-jeunes/id-beneficiaire?onglet=actions',
},
- {}
+ undefined
)
})
})
diff --git a/tests/pages/OffrePage.server.page.test.tsx b/tests/pages/OffrePage.server.page.test.tsx
index f1db57df6..ae8909cc4 100644
--- a/tests/pages/OffrePage.server.page.test.tsx
+++ b/tests/pages/OffrePage.server.page.test.tsx
@@ -57,7 +57,7 @@ describe('OffrePage server side', () => {
{
offre: detailEmploi,
},
- {}
+ undefined
)
})
@@ -102,7 +102,7 @@ describe('OffrePage server side', () => {
{
offre: detailImmersion,
},
- {}
+ undefined
)
})
@@ -151,7 +151,7 @@ describe('OffrePage server side', () => {
{
offre: detailServiceCivique,
},
- {}
+ undefined
)
})
diff --git a/tests/pages/PartageOffrePage.server.test.tsx b/tests/pages/PartageOffrePage.server.test.tsx
index 0e7e5f92c..074c597e1 100644
--- a/tests/pages/PartageOffrePage.server.test.tsx
+++ b/tests/pages/PartageOffrePage.server.test.tsx
@@ -77,7 +77,7 @@ describe('Page Partage Offre', () => {
offre: offreEmploi,
returnTo: 'referer-url',
},
- {}
+ undefined
)
})
@@ -102,7 +102,7 @@ describe('Page Partage Offre', () => {
offre: serviceCivique,
returnTo: 'referer-url',
},
- {}
+ undefined
)
})
@@ -127,7 +127,7 @@ describe('Page Partage Offre', () => {
offre: immersion,
returnTo: 'referer-url',
},
- {}
+ undefined
)
})
@@ -168,7 +168,7 @@ describe('Page Partage Offre', () => {
expect.objectContaining({
returnTo: '/offres',
}),
- {}
+ undefined
)
})
})
diff --git a/tests/pages/PartageRecherchePage.server.test.tsx b/tests/pages/PartageRecherchePage.server.test.tsx
index e5184f7cf..f1fd02342 100644
--- a/tests/pages/PartageRecherchePage.server.test.tsx
+++ b/tests/pages/PartageRecherchePage.server.test.tsx
@@ -64,7 +64,7 @@ describe('Partage Recherche', () => {
},
returnTo: 'referer-url',
},
- {}
+ undefined
)
})
@@ -96,7 +96,7 @@ describe('Partage Recherche', () => {
},
returnTo: 'referer-url',
},
- {}
+ undefined
)
})
@@ -130,7 +130,7 @@ describe('Partage Recherche', () => {
},
returnTo: 'referer-url',
},
- {}
+ undefined
)
})
@@ -160,7 +160,7 @@ describe('Partage Recherche', () => {
},
returnTo: 'referer-url',
},
- {}
+ undefined
)
})
})
diff --git a/tests/pages/PlanDuSite.server.test.tsx b/tests/pages/PlanDuSite.server.test.tsx
index 276862b8c..032d6545b 100644
--- a/tests/pages/PlanDuSite.server.test.tsx
+++ b/tests/pages/PlanDuSite.server.test.tsx
@@ -30,6 +30,6 @@ describe('PlanDuSite server side', () => {
// Then
expect(metadata).toEqual({ title: 'Plan du site' })
- expect(PlanDuSitePage).toHaveBeenCalledWith({}, {})
+ expect(PlanDuSitePage).toHaveBeenCalledWith({}, undefined)
})
})
diff --git a/tests/pages/PortefeuillePage.server.test.tsx b/tests/pages/PortefeuillePage.server.test.tsx
index cbdc59b86..e46354db2 100644
--- a/tests/pages/PortefeuillePage.server.test.tsx
+++ b/tests/pages/PortefeuillePage.server.test.tsx
@@ -83,7 +83,7 @@ describe('PortefeuillePage server side', () => {
}))
.sort(compareBeneficiairesByNom),
}),
- {}
+ undefined
)
})
})
@@ -127,7 +127,7 @@ describe('PortefeuillePage server side', () => {
.sort(compareBeneficiairesByNom),
isFromEmail: false,
},
- {}
+ undefined
)
})
})
diff --git a/tests/pages/ProfilPage.server.test.tsx b/tests/pages/ProfilPage.server.test.tsx
index daf47dd6e..aa8973db6 100644
--- a/tests/pages/ProfilPage.server.test.tsx
+++ b/tests/pages/ProfilPage.server.test.tsx
@@ -29,7 +29,7 @@ describe('ProfilPage server side', () => {
// Then
expect(getAgencesServerSide).not.toHaveBeenCalled()
- expect(ProfilPage).toHaveBeenCalledWith({ referentielAgences: [] }, {})
+ expect(ProfilPage).toHaveBeenCalledWith({ referentielAgences: [] }, undefined)
})
})
@@ -45,7 +45,7 @@ describe('ProfilPage server side', () => {
await renderPageForConseiller(conseiller)
// Then
- expect(ProfilPage).toHaveBeenCalledWith({ referentielAgences: [] }, {})
+ expect(ProfilPage).toHaveBeenCalledWith({ referentielAgences: [] }, undefined)
})
})
@@ -60,7 +60,7 @@ describe('ProfilPage server side', () => {
// Then
expect(ProfilPage).toHaveBeenCalledWith(
{ referentielAgences: uneListeDAgencesMILO() },
- {}
+ undefined
)
})
})
diff --git a/tests/pages/QualificationPage.server.test.tsx b/tests/pages/QualificationPage.server.test.tsx
index df446567d..ca51dc6f3 100644
--- a/tests/pages/QualificationPage.server.test.tsx
+++ b/tests/pages/QualificationPage.server.test.tsx
@@ -157,7 +157,7 @@ describe('QualificationPage server side', () => {
),
returnToListe: '/pilotage',
},
- {}
+ undefined
)
})
})
diff --git a/tests/pages/RaccourciPage.server.test.tsx b/tests/pages/RaccourciPage.server.test.tsx
index eb3c9a0bc..6eb13c6cd 100644
--- a/tests/pages/RaccourciPage.server.test.tsx
+++ b/tests/pages/RaccourciPage.server.test.tsx
@@ -13,6 +13,6 @@ describe("Page Détail d'une action d'un jeune", () => {
render(Raccourci())
// Then
- expect(RaccourciPage).toHaveBeenCalledWith({}, {})
+ expect(RaccourciPage).toHaveBeenCalledWith({}, undefined)
})
})
diff --git a/tests/pages/ReaffectationPage.server.test.tsx b/tests/pages/ReaffectationPage.server.test.tsx
index 93deb0108..b52a479fe 100644
--- a/tests/pages/ReaffectationPage.server.test.tsx
+++ b/tests/pages/ReaffectationPage.server.test.tsx
@@ -40,7 +40,7 @@ describe('Reaffectation', () => {
render(await Reaffectation())
// Then
- expect(ReaffectationPage).toHaveBeenCalledWith({}, {})
+ expect(ReaffectationPage).toHaveBeenCalledWith({}, undefined)
})
})
})
diff --git a/tests/pages/RendezvousPassesPage.server.test.tsx b/tests/pages/RendezvousPassesPage.server.test.tsx
index bb8cc4499..ab5694c66 100644
--- a/tests/pages/RendezvousPassesPage.server.test.tsx
+++ b/tests/pages/RendezvousPassesPage.server.test.tsx
@@ -57,7 +57,7 @@ describe('RendezVousPassesPage server side', () => {
rdvs: [unEvenementListItem()],
lectureSeule: false,
},
- {}
+ undefined
)
})
})
@@ -80,7 +80,7 @@ describe('RendezVousPassesPage server side', () => {
expect(getRendezVousJeune).not.toHaveBeenCalled()
expect(RendezVousPassesPage).toHaveBeenCalledWith(
expect.objectContaining({ rdvs: [] }),
- {}
+ undefined
)
})
})
diff --git a/tests/pages/agenda/AgendaPage.sever.test.tsx b/tests/pages/agenda/AgendaPage.server.test.tsx
similarity index 98%
rename from tests/pages/agenda/AgendaPage.sever.test.tsx
rename to tests/pages/agenda/AgendaPage.server.test.tsx
index 37b563b12..4caa88935 100644
--- a/tests/pages/agenda/AgendaPage.sever.test.tsx
+++ b/tests/pages/agenda/AgendaPage.server.test.tsx
@@ -44,7 +44,7 @@ describe('AgendaPage server side', () => {
// Then
expect(AgendaPage).toHaveBeenCalledWith(
{ onglet: 'ETABLISSEMENT', periodeIndexInitial: 0 },
- {}
+ undefined
)
})
})
diff --git a/tests/pages/aide/AidePage.server.test.tsx b/tests/pages/aide/AidePage.server.test.tsx
index ed8dd5f57..0989508e9 100644
--- a/tests/pages/aide/AidePage.server.test.tsx
+++ b/tests/pages/aide/AidePage.server.test.tsx
@@ -17,6 +17,6 @@ describe('Aide server side', () => {
// Then
expect(metadata).toEqual({ title: 'Aide et ressources' })
- expect(AidePage).toHaveBeenCalledWith({}, {})
+ expect(AidePage).toHaveBeenCalledWith({}, undefined)
})
})
diff --git a/tests/pages/edition-rdv/EditionRdvPage.server.test.tsx b/tests/pages/edition-rdv/EditionRdvPage.server.test.tsx
index 300e47d52..695af14b5 100644
--- a/tests/pages/edition-rdv/EditionRdvPage.server.test.tsx
+++ b/tests/pages/edition-rdv/EditionRdvPage.server.test.tsx
@@ -53,7 +53,7 @@ describe('EditionRdvPage server side', () => {
expect.objectContaining({
returnTo: '/agenda',
}),
- {}
+ undefined
)
})
@@ -75,7 +75,7 @@ describe('EditionRdvPage server side', () => {
expect.objectContaining({
returnTo: '/mes-jeunes',
}),
- {}
+ undefined
)
})
@@ -95,7 +95,7 @@ describe('EditionRdvPage server side', () => {
conseillerEstObservateur: false,
lectureSeule: false,
},
- {}
+ undefined
)
})
@@ -110,7 +110,7 @@ describe('EditionRdvPage server side', () => {
// Then
expect(EditionRdvPage).toHaveBeenCalledWith(
expect.objectContaining({ idBeneficiaire: 'id-jeune' }),
- {}
+ undefined
)
})
@@ -137,7 +137,7 @@ describe('EditionRdvPage server side', () => {
})
expect(EditionRdvPage).toHaveBeenCalledWith(
expect.objectContaining({ evenement }),
- {}
+ undefined
)
})
@@ -187,7 +187,7 @@ describe('EditionRdvPage server side', () => {
conseillerEstObservateur: false,
lectureSeule: false,
},
- {}
+ undefined
)
})
@@ -203,7 +203,7 @@ describe('EditionRdvPage server side', () => {
expect.objectContaining({
typesRendezVous: typesAnimationCollective(),
}),
- {}
+ undefined
)
})
@@ -218,7 +218,7 @@ describe('EditionRdvPage server side', () => {
// Then
expect(EditionRdvPage).toHaveBeenCalledWith(
expect.objectContaining({ idBeneficiaire: 'id-jeune' }),
- {}
+ undefined
)
})
@@ -247,7 +247,7 @@ describe('EditionRdvPage server side', () => {
evenement: animationCollective,
evenementTypeAC: true,
}),
- {}
+ undefined
)
})
diff --git a/tests/pages/fiche-jeune/FicheBeneficiairePage.server.test.tsx b/tests/pages/fiche-jeune/FicheBeneficiairePage.server.test.tsx
index f4df580e6..67532b9c2 100644
--- a/tests/pages/fiche-jeune/FicheBeneficiairePage.server.test.tsx
+++ b/tests/pages/fiche-jeune/FicheBeneficiairePage.server.test.tsx
@@ -128,7 +128,7 @@ describe('FicheBeneficiairePage server side', () => {
lectureSeule: false,
erreurSessions: false,
},
- {}
+ undefined
)
})
@@ -146,7 +146,7 @@ describe('FicheBeneficiairePage server side', () => {
)
expect(FicheBeneficiairePage).toHaveBeenCalledWith(
expect.objectContaining({ rdvs: [rdvAVenir, sessionsAVenir] }),
- {}
+ undefined
)
})
@@ -158,7 +158,7 @@ describe('FicheBeneficiairePage server side', () => {
)
expect(FicheBeneficiairePage).toHaveBeenCalledWith(
expect.objectContaining({ metadonneesFavoris: uneMetadonneeFavoris() }),
- {}
+ undefined
)
})
@@ -182,7 +182,7 @@ describe('FicheBeneficiairePage server side', () => {
metadonnees: { nombreTotal: 14, nombrePages: 2 },
},
}),
- {}
+ undefined
)
})
})
@@ -209,7 +209,7 @@ describe('FicheBeneficiairePage server side', () => {
page: 3,
}),
}),
- {}
+ undefined
)
})
})
@@ -227,7 +227,7 @@ describe('FicheBeneficiairePage server side', () => {
// Then
expect(FicheBeneficiairePage).toHaveBeenCalledWith(
expect.objectContaining({ ongletInitial: 'rdvs' }),
- {}
+ undefined
)
})
})
@@ -260,7 +260,7 @@ describe('FicheBeneficiairePage server side', () => {
expect(getSessionsMiloBeneficiaire).not.toHaveBeenCalled()
expect(FicheBeneficiairePage).toHaveBeenCalledWith(
expect.not.objectContaining({ rdvs: expect.arrayContaining([]) }),
- {}
+ undefined
)
})
@@ -273,7 +273,7 @@ describe('FicheBeneficiairePage server side', () => {
actions: expect.arrayContaining([]),
}),
}),
- {}
+ undefined
)
})
@@ -283,7 +283,7 @@ describe('FicheBeneficiairePage server side', () => {
expect.objectContaining({
favorisOffres: uneListeDOffres(),
}),
- {}
+ undefined
)
})
@@ -296,7 +296,7 @@ describe('FicheBeneficiairePage server side', () => {
expect.objectContaining({
favorisRecherches: uneListeDeRecherches(),
}),
- {}
+ undefined
)
})
})
@@ -336,7 +336,7 @@ describe('FicheBeneficiairePage server side', () => {
isStale: false,
},
}),
- {}
+ undefined
)
})
})
@@ -360,7 +360,7 @@ describe('FicheBeneficiairePage server side', () => {
expect(FicheBeneficiairePage).toHaveBeenCalledWith(
expect.objectContaining({ lectureSeule: true }),
- {}
+ undefined
)
})
})
diff --git a/tests/pages/layouts/LayoutWhenConnected.test.tsx b/tests/pages/layouts/LayoutWhenConnected.test.tsx
index 6f27ad049..96e0663c2 100644
--- a/tests/pages/layouts/LayoutWhenConnected.test.tsx
+++ b/tests/pages/layouts/LayoutWhenConnected.test.tsx
@@ -108,7 +108,7 @@ describe('LayoutWhenConnected', () => {
)
expect(ConseillerProvider).toHaveBeenCalledWith(
expect.objectContaining({ conseiller }),
- {}
+ undefined
)
})
@@ -124,7 +124,7 @@ describe('LayoutWhenConnected', () => {
extractBaseBeneficiaire
),
}),
- {}
+ undefined
)
})
})
diff --git a/tests/pages/pilotage/PilotagePage.server.test.tsx b/tests/pages/pilotage/PilotagePage.server.test.tsx
index 76ec20894..7199cec78 100644
--- a/tests/pages/pilotage/PilotagePage.server.test.tsx
+++ b/tests/pages/pilotage/PilotagePage.server.test.tsx
@@ -126,7 +126,7 @@ describe('PilotagePage server side', () => {
sessions: uneListeDeSessionsAClore(),
onglet: 'ACTIONS',
},
- {}
+ undefined
)
})
@@ -162,7 +162,7 @@ describe('PilotagePage server side', () => {
animationsCollectives: undefined,
sessions: undefined,
},
- {}
+ undefined
)
})
@@ -190,7 +190,7 @@ describe('PilotagePage server side', () => {
animationsCollectives: undefined,
sessions: undefined,
},
- {}
+ undefined
)
})
})
diff --git a/tests/utils/chatsContext.test.tsx b/tests/utils/chatsContext.test.tsx
index 40379885a..0a24d2387 100644
--- a/tests/utils/chatsContext.test.tsx
+++ b/tests/utils/chatsContext.test.tsx
@@ -1,4 +1,4 @@
-import { RenderResult, act, render, screen } from '@testing-library/react'
+import { act, render, RenderResult } from '@testing-library/react'
import React from 'react'
import {
@@ -93,9 +93,10 @@ describe('ChatsProvider', () => {
it('affiche une notification dans l’onglet s’il y a des messages non lus', async () => {
// Then
- expect(
- renderResult.container.querySelector("link[rel='icon']")
- ).toHaveProperty('href', 'http://localhost/cej-favicon-notif.png')
+ expect(document.querySelector("link[rel='icon']")).toHaveProperty(
+ 'href',
+ 'http://localhost/cej-favicon-notif.png'
+ )
expect(document.title).toMatch(/Nouveau\(x\) message\(s\) - /)
})