diff --git a/functests/toulouse_maelis/data/test_create_family_out_town.json b/functests/toulouse_maelis/data/test_create_family_out_town.json index 2cdc8e23..875dba9d 100644 --- a/functests/toulouse_maelis/data/test_create_family_out_town.json +++ b/functests/toulouse_maelis/data/test_create_family_out_town.json @@ -70,7 +70,8 @@ "countryCode": null, "cdDepartment": "19", "communeCode_text": "BRIVE-LA-GAILLARDE", - "cdDepartment_text": "CORREZE" + "cdDepartment_text": "CORREZE", + "zipCode": "19100" }, "adresse": { "idStreet": "2317", @@ -145,7 +146,8 @@ "countryCode": null, "cdDepartment": "19", "communeCode_text": "BRIVE-LA-GAILLARDE", - "cdDepartment_text": "CORREZE" + "cdDepartment_text": "CORREZE", + "zipCode": "19100" }, "dietcode": "MENU_AV", "bPhoto": true, diff --git a/functests/toulouse_maelis/test_02_family.py b/functests/toulouse_maelis/test_02_family.py index 218599ba..9105f800 100644 --- a/functests/toulouse_maelis/test_02_family.py +++ b/functests/toulouse_maelis/test_02_family.py @@ -914,7 +914,6 @@ def test_read_family_members(conn, update_data): assert res['data']['personInfo']['firstname'] == 'ABRAHAM JEBEDIAH' -@pytest.mark.xfail(run=False) def test_add_supplied_document(conn, create_data): unlink(conn, create_data['name_id']) link(conn, create_data) diff --git a/functests/toulouse_maelis/test_03_petite_enfance.py b/functests/toulouse_maelis/test_03_petite_enfance.py index 0c5ac28b..3f88ed2c 100644 --- a/functests/toulouse_maelis/test_03_petite_enfance.py +++ b/functests/toulouse_maelis/test_03_petite_enfance.py @@ -3,8 +3,13 @@ import datetime import pytest import requests +from .conftest import link, unlink + def test_create_nursery_demand_on_existing_child(conn, create_data): + unlink(conn, create_data['name_id']) + link(conn, create_data) + url = conn + '/get-nursery-geojson' resp = requests.get(url) resp.raise_for_status() @@ -57,6 +62,9 @@ def test_create_nursery_demand_on_existing_child(conn, create_data): def test_create_nursery_demand_adding_new_child(conn, create_data): + unlink(conn, create_data['name_id']) + link(conn, create_data) + url = conn + '/get-nursery-geojson' resp = requests.get(url) resp.raise_for_status() @@ -70,6 +78,7 @@ def test_create_nursery_demand_adding_new_child(conn, create_data): res = resp.json() assert res['err'] == 0 nb_childs = len(res['data']['childList']) + assert 'NELSON' not in [x['firstname'] for x in res['data']['childList']] url = conn + '/create-nursery-demand' payload = { @@ -102,4 +111,5 @@ def test_create_nursery_demand_adding_new_child(conn, create_data): res = resp.json() assert res['err'] == 0 assert len(res['data']['childList']) == nb_childs + 1 + assert 'NELSON' in [x['firstname'] for x in res['data']['childList']] assert res['data']['childList'][nb_childs]['num'] == child_id diff --git a/functests/toulouse_maelis/test_05_perisco.py b/functests/toulouse_maelis/test_05_perisco.py index 2f8baa5f..4b659be8 100644 --- a/functests/toulouse_maelis/test_05_perisco.py +++ b/functests/toulouse_maelis/test_05_perisco.py @@ -205,11 +205,10 @@ def test_perisco_recurrent_week(conn, create_data, perisco_subscribe_info, refer resp = requests.get(url, params=params) resp.raise_for_status() assert resp.json()['err'] == 0 - assert len(resp.json()['data']) == 2 + assert len(resp.json()['data']) == 1 assert resp.json()['data'][0]['id'] == perisco_subscribe_info['activity']['id'] assert [(x['text'], x['libelle'], x['libelle2']) for x in resp.json()['data']] == [ ('Temps du midi', 'TEST TEMPS DU MIDI 22/23', 'Temps du midi'), - ('Temps du midi', 'TEST TEMPS DU MIDI 22/23', 'Temps du midi'), ] # get recurent-week gabarit diff --git a/functests/toulouse_maelis/test_07_extrasco.py b/functests/toulouse_maelis/test_07_extrasco.py index 39a8d514..a81a1b4c 100644 --- a/functests/toulouse_maelis/test_07_extrasco.py +++ b/functests/toulouse_maelis/test_07_extrasco.py @@ -13,6 +13,7 @@ def test_catalog_personnalise_extrasco(extrasco_subscribe_info): 'quantity': None, 'unitPrice': 11.5, } + assert item['activity']['activityPortail']['blocNoteList'] == [] def test_catalog_personnalise_extrasco2(extrasco_subscribe_info2): @@ -26,6 +27,7 @@ def test_catalog_personnalise_extrasco2(extrasco_subscribe_info2): 'quantity': None, 'unitPrice': 11.5, } + assert item['activity']['activityPortail']['blocNoteList'] == [] def test_direct_subscribe(conn, create_data, extrasco_subscribe_info, reference_year):