fix: ajouter mission locale dans le mecanisme de process ingestion #151
Annotations
7 errors and 1 warning
tests/integration/jobs/ingestion/process-ingestion.test.ts > Processus d'ingestion > Ingestion de données valides > Ingestion de nouvelles données valides > Vérifie l'ingestion valide d'un nouveau dossier valide pour un organisme fiable et que la donnée est bien trimmée:
server/tests/integration/jobs/ingestion/process-ingestion.test.ts#L188
AssertionError: expected { …(14) } to strictly equal { source: 'ERP', …(13) }
- Expected
+ Received
Object {
"_computed": Object {
"formation": Object {
"codes_rome": Array [
"D1202",
],
"opcos": Array [],
},
"organisme": Object {
"academie": "10",
"departement": "01",
"fiable": false,
"region": "84",
"reseaux": Array [],
"siret": "77937827200016",
"uai": "0802004U",
},
"statut": Object {
"en_cours": "FIN_DE_FORMATION",
"parcours": Array [
Object {
"date": 2021-08-01T00:00:00.000Z,
"valeur": "INSCRIT",
},
Object {
"date": 2022-12-28T04:05:47.647Z,
"valeur": "APPRENTI",
},
Object {
"date": 2023-07-31T00:00:00.000Z,
"valeur": "FIN_DE_FORMATION",
},
],
},
},
"_id": Anything,
"_raw": Object {
"formation": Object {
"annee": 0,
"cfd": "50033610",
"libelle_long": "TECHNICIEN D'ETUDES DU BATIMENT OPTION A : ETUDES ET ECONOMIE (BAC PRO)",
"periode": Array [
2021,
2023,
],
},
},
"annee_scolaire": "2022-2023",
"apprenant": Object {
"adresse": Object {
"academie": "02",
"code_insee": "05109",
"code_postal": "05100",
"commune": "Puy-Saint-Pierre",
"departement": "05",
+ "mission_locale_id": 211,
"region": "93",
},
"courriel": "[email protected]",
"date_de_naissance": 1999-08-31T16:21:32.000Z,
"historique_statut": Array [
Object {
"date_reception": Anything,
"date_statut": 2022-12-28T04:05:47.647Z,
"valeur_statut": 3,
},
],
"ine": "402957826QH",
"nom": "FLEURY",
"prenom": "Fortuné",
"telephone": "+33534648662",
},
"contrats": Array [],
"created_at": Any<Date>,
"formation": Object {
"annee": 0,
"cfd": "50033616",
"libelle_court": "METIERS DE LA COIFFURE",
"libelle_long": "METIERS DE LA COIFFURE (CAP)",
"niveau": "3",
"niveau_libelle": "3 (CAP...)",
"periode": Array [
2021,
2023,
],
"rncp": "RNCP34670",
},
"id_erp_apprenant": "9a890d67-e233-46d5-8611-06d6648e7611",
"is_lock": Object {
"apprenant": Object {
"adresse": Object {
"academie": true,
"code_insee": true,
"code_postal": true,
"commune": true,
"departement": true,
+ "mission_locale_id": true,
"region": true,
},
"courriel": true,
"date_de_naissance": true,
"historique_statut": true,
"ine": true,
"nom": true,
"prenom": true,
"telephone": true,
},
"contrats": true,
"formation": Object {
"annee": true,
"cfd": true,
"libelle_court": true,
"libelle_long": true,
"niveau": true,
"niveau_libelle": true,
"periode": true,
"rncp": true,
},
},
"organisme_id": Any<ObjectId>,
"source": "ERP",
"updated_at": Any<Date>,
"validation_errors": Array [],
}
❯ tests/integration/jobs/ingestion/process-ingestion.test.ts:188:33
|
tests/integration/jobs/ingestion/process-ingestion.test.ts > Processus d'ingestion > Ingestion de données valides > Ingestion de nouvelles données valides v3 > Vérifie l'ingestion valide d'un nouveau dossier valide v3 pour un organisme fiable:
server/tests/integration/jobs/ingestion/process-ingestion.test.ts#L568
AssertionError: expected { …(18) } to strictly equal { …(18) }
- Expected
+ Received
Object {
"_computed": Object {
"formation": Object {
"codes_rome": null,
"opcos": Array [],
},
"organisme": Object {
"academie": "10",
"departement": "01",
"fiable": false,
"region": "84",
"reseaux": Array [],
"siret": "77937827200016",
"uai": "0802004U",
},
"statut": Object {
"en_cours": "FIN_DE_FORMATION",
"parcours": Array [
Object {
"date": 2021-09-01T00:00:00.000Z,
"valeur": "INSCRIT",
},
Object {
"date": 2021-09-01T00:00:00.000Z,
"valeur": "APPRENTI",
},
Object {
"date": 2022-06-30T00:00:00.000Z,
"valeur": "RUPTURANT",
},
Object {
"date": 2022-06-30T00:00:00.000Z,
"valeur": "FIN_DE_FORMATION",
},
],
},
},
"_id": "6761b21807bf21c2cd2f227a",
"_raw": Object {
"formation": Object {
"annee": 1,
"cause_exclusion": "absences répétées et injustifiées",
"cfd": "1234ABCD",
"date_entree": 2021-09-01T00:00:00.000Z,
"date_exclusion": 2022-06-30T00:00:00.000Z,
"date_fin": 2022-06-30T00:00:00.000Z,
"date_inscription": 2021-09-01T00:00:00.000Z,
"date_obtention_diplome": 2022-06-30T00:00:00.000Z,
"duree_formation_relle": 10,
"duree_theorique_mois": 24,
"formation_presentielle": true,
"obtention_diplome": true,
"periode": Array [],
"referent_handicap": Object {
"email": "[email protected]",
"nom": "Doe",
"prenom": "John",
},
"rncp": "RNCP5364",
},
},
"annee_scolaire": "2021-2022",
"apprenant": Object {
"adresse": Object {
"academie": "01",
"code_insee": "75056",
"code_postal": "75001",
"commune": "Paris",
"complete": "1 rue de la paix",
"departement": "75",
+ "mission_locale_id": 609,
"region": "11",
},
"code_postal_de_naissance": "44000",
"courriel": "[email protected]",
"date_de_naissance": 2000-10-28T00:00:00.000Z,
"date_rqth": 2021-09-01T00:00:00.000Z,
"dernier_organisme_uai": "1234567X",
"derniere_situation": 4001,
"has_nir": true,
"historique_statut": Array [
Object {
"date_reception": Any<Date>,
"date_statut": 2022-12-28T04:05:47.647Z,
"valeur_statut": 2,
},
],
"ine": "1234567890A",
"nom": "DOE",
"prenom": "John",
"responsable_mail1": "[email protected]",
"responsable_mail2": "[email protected]",
"rqth": true,
"sexe": "F",
"telephone": "0123456789",
"type_cfa": "04",
},
"contrats": Array [
Object {
"cause_rupture": "abandon",
"date_debut": 2021-09-01T00:00:00.000Z,
"date_fin": 2022-06-30T00:00:00.000Z,
"date_rupture": 2022-06-30T00:00:00.000Z,
"siret": "12345678901234",
},
Object {
"cause_rupture": "abandon",
"date_debut": 2021-09-01T00:00:00.000Z,
"date_fin": 2022-06-30T00:00:00.000Z,
"date_rupture": 2022-06-30T00:00:00.000Z,
"siret": "12345678901234",
},
],
"created_at": Any<Date>,
"formation": Object {
"annee": 1,
"cause_exclusion": "absences répétées et injustifiées",
"cfd": "1234ABCD",
"date_entree": 2021-09-01T00:00:00.000Z,
"date_exclusion": 2022-06-30T00:00:00.000Z,
"date_fin": 2022-06-30T00:00:00.000Z,
"date_inscription": 2021-09-01T00:00:00.000Z,
"date_obtention_diplome": 2022-06-30T00:00:00.000Z,
"duree_formation_relle": 10,
"duree_theorique_mois": 24,
"formation_presentielle": true,
"obtention_diplome": true,
"periode": Array [],
"referent_handicap": Object {
"email": "[email protected]",
|
src/common/mongodb/validationSchema.test.ts > validation-schema > should create validation schema for organismes:
server/src/common/mongodb/validationSchema.test.ts#L9
Error: Snapshot `validation-schema > should create validation schema for organismes > organismes 1` mismatched
- Expected
+ Received
@@ -47,10 +47,14 @@
},
"departement": {
"bsonType": "string",
"pattern": "^(2A|2B|[0-9]{2,3})$",
},
+ "mission_locale_id": {
+ "bsonType": "number",
+ "description": "Id de mission locale",
+ },
"numero": {
"bsonType": "int",
"description": "N° de la voie",
},
"pays": {
@@ -1059,10 +1063,14 @@
"description": "Adresse complète",
},
"departement": {
"bsonType": "string",
"pattern": "^(2A|2B|[0-9]{2,3})$",
+ },
+ "mission_locale_id": {
+ "bsonType": "number",
+ "description": "Id de mission locale",
},
"numero": {
"bsonType": "int",
"description": "N° de la voie",
},
❯ src/common/mongodb/validationSchema.test.ts:9:48
|
src/common/mongodb/validationSchema.test.ts > validation-schema > should create validation schema for effectifs:
server/src/common/mongodb/validationSchema.test.ts#L9
Error: Snapshot `validation-schema > should create validation schema for effectifs > effectifs 1` mismatched
- Expected
+ Received
@@ -46,29 +46,10 @@
{
"bsonType": "null",
},
],
},
- "missionLocale": {
- "anyOf": [
- {
- "additionalProperties": false,
- "bsonType": "object",
- "properties": {
- "id": {
- "bsonType": "string",
- },
- },
- "required": [
- "id",
- ],
- },
- {
- "bsonType": "null",
- },
- ],
- },
"organisme": {
"anyOf": [
{
"additionalProperties": false,
"bsonType": "object",
@@ -609,10 +590,14 @@
"description": "Adresse complète",
},
"departement": {
"bsonType": "string",
"pattern": "^(2A|2B|[0-9]{2,3})$",
+ },
+ "mission_locale_id": {
+ "bsonType": "number",
+ "description": "Id de mission locale",
},
"numero": {
"bsonType": "int",
"description": "N° de la voie",
},
@@ -1229,10 +1214,14 @@
},
"departement": {
"bsonType": "string",
"pattern": "^(2A|2B|[0-9]{2,3})$",
},
+ "mission_locale_id": {
+ "bsonType": "number",
+ "description": "Id de mission locale",
+ },
"numero": {
"bsonType": "int",
"description": "N° de la voie",
},
"pays": {
@@ -1724,10 +1713,14 @@
"description": "Adresse complète",
},
"departement": {
"bsonType": "string",
"pattern": "^(2A|2B|[0-9]{2,3})$",
+ },
+ "mission_locale_id": {
+ "bsonType": "number",
+ "description": "Id de mission locale",
},
"numero": {
"bsonType": "int",
"description": "N° de la voie",
},
❯ src/common/mongodb/validationSchema.test.ts:9:48
|
src/common/mongodb/validationSchema.test.ts > validation-schema > should create validation schema for effectifsDECA:
server/src/common/mongodb/validationSchema.test.ts#L9
Error: Snapshot `validation-schema > should create validation schema for effectifsDECA > effectifsDECA 1` mismatched
- Expected
+ Received
@@ -623,10 +623,14 @@
},
"departement": {
"bsonType": "string",
"pattern": "^(2A|2B|[0-9]{2,3})$",
},
+ "mission_locale_id": {
+ "bsonType": "number",
+ "description": "Id de mission locale",
+ },
"numero": {
"bsonType": "int",
"description": "N° de la voie",
},
"pays": {
@@ -1092,10 +1096,14 @@
"description": "Adresse complète",
},
"departement": {
"bsonType": "string",
"pattern": "^(2A|2B|[0-9]{2,3})$",
+ },
+ "mission_locale_id": {
+ "bsonType": "number",
+ "description": "Id de mission locale",
},
"numero": {
"bsonType": "int",
"description": "N° de la voie",
},
❯ src/common/mongodb/validationSchema.test.ts:9:48
|
src/common/mongodb/validationSchema.test.ts > validation-schema > should create validation schema for effectifsArchive:
server/src/common/mongodb/validationSchema.test.ts#L9
Error: Snapshot `validation-schema > should create validation schema for effectifsArchive > effectifsArchive 1` mismatched
- Expected
+ Received
@@ -46,29 +46,10 @@
{
"bsonType": "null",
},
],
},
- "missionLocale": {
- "anyOf": [
- {
- "additionalProperties": false,
- "bsonType": "object",
- "properties": {
- "id": {
- "bsonType": "string",
- },
- },
- "required": [
- "id",
- ],
- },
- {
- "bsonType": "null",
- },
- ],
- },
"organisme": {
"anyOf": [
{
"additionalProperties": false,
"bsonType": "object",
@@ -609,10 +590,14 @@
"description": "Adresse complète",
},
"departement": {
"bsonType": "string",
"pattern": "^(2A|2B|[0-9]{2,3})$",
+ },
+ "mission_locale_id": {
+ "bsonType": "number",
+ "description": "Id de mission locale",
},
"numero": {
"bsonType": "int",
"description": "N° de la voie",
},
@@ -1229,10 +1214,14 @@
},
"departement": {
"bsonType": "string",
"pattern": "^(2A|2B|[0-9]{2,3})$",
},
+ "mission_locale_id": {
+ "bsonType": "number",
+ "description": "Id de mission locale",
+ },
"numero": {
"bsonType": "int",
"description": "N° de la voie",
},
"pays": {
@@ -1724,10 +1713,14 @@
"description": "Adresse complète",
},
"departement": {
"bsonType": "string",
"pattern": "^(2A|2B|[0-9]{2,3})$",
+ },
+ "mission_locale_id": {
+ "bsonType": "number",
+ "description": "Id de mission locale",
},
"numero": {
"bsonType": "int",
"description": "N° de la voie",
},
❯ src/common/mongodb/validationSchema.test.ts:9:48
|
tests / Tests
Process completed with exit code 1.
|
tests / Tests
ubuntu-latest pipelines will use ubuntu-24.04 soon. For more details, see https://github.com/actions/runner-images/issues/10636
|