diff --git a/tests/fixtures/ntfs_with_windows/input/booking_rule_links.txt b/tests/fixtures/ntfs_with_windows/input/booking_rule_links.txt new file mode 100644 index 000000000..5c76ae929 --- /dev/null +++ b/tests/fixtures/ntfs_with_windows/input/booking_rule_links.txt @@ -0,0 +1,4 @@ +object_id,object_type,booking_rule_id +MFDI:KVVB:158023-C02513-1638-260,trip,MFDI:10 +MFDI:BOUCLE_DE_LYS:149996-C02491-18777678,trip,MFDI:12 +MFDI:KRO6:153358-C02060-680-260,trip,MFDI:11 diff --git a/tests/fixtures/ntfs_with_windows/input/booking_rules.txt b/tests/fixtures/ntfs_with_windows/input/booking_rules.txt new file mode 100644 index 000000000..92b6816d3 --- /dev/null +++ b/tests/fixtures/ntfs_with_windows/input/booking_rules.txt @@ -0,0 +1,4 @@ +booking_rule_id,name,info_url,phone_number,message,booking_url +MFDI:10,sans_reservation,,,"Bus de soirée : Le service fonctionne sans réservation, il suffit d'indiquer l'arrêt de descente au conducteur", +MFDI:11,avec_reservation,https://www.fileo.com/se-deplacer/reserver-votre-fileo/,01 74 37 24 77,24h/24 et 7j/7, +MFDI:12,sans_reservation,,,, diff --git a/tests/fixtures/ntfs_with_windows/input/calendar.txt b/tests/fixtures/ntfs_with_windows/input/calendar.txt new file mode 100644 index 000000000..01fd2617d --- /dev/null +++ b/tests/fixtures/ntfs_with_windows/input/calendar.txt @@ -0,0 +1,3 @@ +service_id,monday,tuesday,wednesday,thursday,friday,saturday,sunday,start_date,end_date +MFDI:1,1,1,1,1,1,0,0,20240916,20241015 +MFDI:1000,1,1,1,1,1,1,1,20240916,20241015 diff --git a/tests/fixtures/ntfs_with_windows/input/commercial_modes.txt b/tests/fixtures/ntfs_with_windows/input/commercial_modes.txt new file mode 100644 index 000000000..0cf491854 --- /dev/null +++ b/tests/fixtures/ntfs_with_windows/input/commercial_modes.txt @@ -0,0 +1,3 @@ +commercial_mode_id,commercial_mode_name +Bus,Bus +Metro,Métro diff --git a/tests/fixtures/ntfs_with_windows/input/companies.txt b/tests/fixtures/ntfs_with_windows/input/companies.txt new file mode 100644 index 000000000..052b8e962 --- /dev/null +++ b/tests/fixtures/ntfs_with_windows/input/companies.txt @@ -0,0 +1,5 @@ +company_id,company_name,company_address,company_url,company_mail,company_phone +MFDI:100,RATP,,,, +MFDI:1017,Keolis Vélizy Vallée de la Bièvre,,,, +MFDI:1028,Keolis Roissy Pays de France Ouest,,,, +MFDI:1021,Transdev Boucle des Lys,,,, diff --git a/tests/fixtures/ntfs_with_windows/input/contributors.txt b/tests/fixtures/ntfs_with_windows/input/contributors.txt new file mode 100644 index 000000000..cbb88ece5 --- /dev/null +++ b/tests/fixtures/ntfs_with_windows/input/contributors.txt @@ -0,0 +1,2 @@ +contributor_id,contributor_name,contributor_license,contributor_website +MFDI:ntx,ntx,public, diff --git a/tests/fixtures/ntfs_with_windows/input/datasets.txt b/tests/fixtures/ntfs_with_windows/input/datasets.txt new file mode 100644 index 000000000..eb8273f33 --- /dev/null +++ b/tests/fixtures/ntfs_with_windows/input/datasets.txt @@ -0,0 +1,2 @@ +dataset_id,contributor_id,dataset_start_date,dataset_end_date,dataset_type,dataset_extrapolation,dataset_desc,dataset_system +MFDI:4c649e1d-f7e4-4622-b6df-30e0997704af,MFDI:ntx,20240916,20241015,,0,, diff --git a/tests/fixtures/ntfs_with_windows/input/equipments.txt b/tests/fixtures/ntfs_with_windows/input/equipments.txt new file mode 100644 index 000000000..1fbd753ad --- /dev/null +++ b/tests/fixtures/ntfs_with_windows/input/equipments.txt @@ -0,0 +1,4 @@ +equipment_id,wheelchair_boarding,sheltered,elevator,escalator,bike_accepted,bike_depot,visual_announcement,audible_announcement,appropriate_escort,appropriate_signage +MFDI:1,1,0,0,0,0,0,0,0,0,0 +MFDI:2,2,0,0,0,0,0,0,0,0,0 +MFDI:3,2,0,0,0,0,0,1,1,0,0 diff --git a/tests/fixtures/ntfs_with_windows/input/feed_infos.txt b/tests/fixtures/ntfs_with_windows/input/feed_infos.txt new file mode 100644 index 000000000..c0b75d89c --- /dev/null +++ b/tests/fixtures/ntfs_with_windows/input/feed_infos.txt @@ -0,0 +1,7 @@ +feed_info_param,feed_info_value +feed_creation_date,20240918 +feed_creation_datetime,2024-09-18T11:33:52+00:00 +feed_creation_time,11:33:52 +feed_end_date,20241015 +feed_start_date,20240916 +ntfs_version,0.18.0 diff --git a/tests/fixtures/ntfs_with_windows/input/lines.txt b/tests/fixtures/ntfs_with_windows/input/lines.txt new file mode 100644 index 000000000..726bc2261 --- /dev/null +++ b/tests/fixtures/ntfs_with_windows/input/lines.txt @@ -0,0 +1,5 @@ +line_id,line_code,line_name,forward_line_name,backward_line_name,line_color,line_text_color,line_sort_order,network_id,commercial_mode_id,geometry_id,line_opening_time,line_closing_time +MFDI:C01376,6,6,,,6ECA97,0,,MFDI:Operator_100,Metro,,, +MFDI:C02060,Filéo RS,Filéo Roissy Sud - Villeparisis et Mitry (sur réservation),,,4890CD,FFFFFF,,MFDI:1071,Bus,,, +MFDI:C02491,Soir,Soir Saint-Germain-en-Laye,,,652C8F,FFFFFF,,MFDI:1062,Bus,,, +MFDI:C02513,Soir,Soir Versailles-Chantiers,,,640082,FFFFFF,,MFDI:1061,Bus,,, diff --git a/tests/fixtures/ntfs_with_windows/input/networks.txt b/tests/fixtures/ntfs_with_windows/input/networks.txt new file mode 100644 index 000000000..6d82bb8f7 --- /dev/null +++ b/tests/fixtures/ntfs_with_windows/input/networks.txt @@ -0,0 +1,5 @@ +network_id,network_name,network_url,network_timezone,network_lang,network_phone,network_address,network_fare_url,network_sort_order +MFDI:1061,Vélizy Vallées,https://www.iledefrance-mobilites.fr,Europe/Paris,,,,https://applidium.page.link/default, +MFDI:1071,Roissy Ouest,https://www.iledefrance-mobilites.fr,Europe/Paris,,,,https://applidium.page.link/default, +MFDI:1062,Saint Germain Boucles de Seine,https://www.iledefrance-mobilites.fr,Europe/Paris,,,,https://applidium.page.link/default, +MFDI:Operator_100,RATP,https://www.iledefrance-mobilites.fr,Europe/Paris,,,,https://applidium.page.link/default, diff --git a/tests/fixtures/ntfs_with_windows/input/object_codes.txt b/tests/fixtures/ntfs_with_windows/input/object_codes.txt new file mode 100644 index 000000000..9727314a6 --- /dev/null +++ b/tests/fixtures/ntfs_with_windows/input/object_codes.txt @@ -0,0 +1,211 @@ +object_type,object_id,object_system,object_code +stop_area,MFDI:461827,source,FR::multimodalStopPlace:461827:FR1 +stop_area,MFDI:426072,source,FR::multimodalStopPlace:426072:FR1 +stop_area,MFDI:71639,source,FR::multimodalStopPlace:71639:FR1 +stop_area,MFDI:71673,TN_PA,484 +stop_area,MFDI:71673,source,FR::multimodalStopPlace:71673:FR1 +stop_area,MFDI:64589,TN_PA,476 +stop_area,MFDI:64589,source,FR::multimodalStopPlace:64589:FR1 +stop_area,MFDI:63880,TN_PA,210 +stop_area,MFDI:63880,source,FR::multimodalStopPlace:63880:FR1 +stop_area,MFDI:71026,source,FR::multimodalStopPlace:71026:FR1 +stop_area,MFDI:64509,source,FR::multimodalStopPlace:64509:FR1 +stop_area,MFDI:64485,source,FR::multimodalStopPlace:64485:FR1 +stop_area,MFDI:63534,source,FR::multimodalStopPlace:63534:FR1 +stop_area,MFDI:63529,source,FR::multimodalStopPlace:63529:FR1 +stop_area,MFDI:63438,source,FR::multimodalStopPlace:63438:FR1 +stop_area,MFDI:73556,source,FR::multimodalStopPlace:73556:FR1 +stop_area,MFDI:73596,TN_PA,376 +stop_area,MFDI:73596,source,FR::multimodalStopPlace:73596:FR1 +stop_area,MFDI:73591,source,FR::multimodalStopPlace:73591:FR1 +stop_area,MFDI:71347,TN_PA,482 +stop_area,MFDI:71347,source,FR::multimodalStopPlace:71347:FR1 +stop_area,MFDI:73486,source,FR::multimodalStopPlace:73486:FR1 +stop_area,MFDI:71199,source,FR::multimodalStopPlace:71199:FR1 +stop_area,MFDI:480959,source,FR::multimodalStopPlace:480959:FR1 +stop_point,MFDI:22167,netex_monomodal_stopplace,monomodalStopPlace:44334 +stop_point,MFDI:22167,netex_zder_quay,22167 +stop_point,MFDI:22167,netex_zder_quay,463098 +stop_point,MFDI:22167,netex_zder_quay,monomodalStopPlace:44334 +stop_point,MFDI:22167,source,FR::Quay:22167:FR1 +stop_point,MFDI:22173,netex_monomodal_stopplace,monomodalStopPlace:45276 +stop_point,MFDI:22173,netex_zder_quay,22173 +stop_point,MFDI:22173,netex_zder_quay,463186 +stop_point,MFDI:22173,netex_zder_quay,monomodalStopPlace:45276 +stop_point,MFDI:22173,source,FR::Quay:22173:FR1 +stop_point,MFDI:22073,netex_monomodal_stopplace,monomodalStopPlace:462358 +stop_point,MFDI:22073,netex_zder_quay,21919 +stop_point,MFDI:22073,netex_zder_quay,22072 +stop_point,MFDI:22073,netex_zder_quay,22073 +stop_point,MFDI:22073,netex_zder_quay,22080 +stop_point,MFDI:22073,netex_zder_quay,462942 +stop_point,MFDI:22073,netex_zder_quay,462943 +stop_point,MFDI:22073,netex_zder_quay,463028 +stop_point,MFDI:22073,netex_zder_quay,463067 +stop_point,MFDI:22073,netex_zder_quay,monomodalStopPlace:462358 +stop_point,MFDI:22073,source,FR::Quay:22073:FR1 +stop_point,MFDI:41403,netex_monomodal_stopplace,monomodalStopPlace:425035 +stop_point,MFDI:41403,netex_zder_quay,41403 +stop_point,MFDI:41403,netex_zder_quay,472884 +stop_point,MFDI:41403,netex_zder_quay,monomodalStopPlace:425035 +stop_point,MFDI:41403,source,FR::Quay:41403:FR1 +stop_point,MFDI:463194,netex_monomodal_stopplace,monomodalStopPlace:43566 +stop_point,MFDI:463194,netex_zder_quay,21969 +stop_point,MFDI:463194,netex_zder_quay,22162 +stop_point,MFDI:463194,netex_zder_quay,22183 +stop_point,MFDI:463194,netex_zder_quay,463194 +stop_point,MFDI:463194,netex_zder_quay,463201 +stop_point,MFDI:463194,netex_zder_quay,463202 +stop_point,MFDI:463194,netex_zder_quay,monomodalStopPlace:43566 +stop_point,MFDI:463194,source,FR::Quay:463194:FR1 +stop_point,MFDI:463042,netex_monomodal_stopplace,monomodalStopPlace:477682 +stop_point,MFDI:463042,netex_zder_quay,22086 +stop_point,MFDI:463042,netex_zder_quay,22094 +stop_point,MFDI:463042,netex_zder_quay,22095 +stop_point,MFDI:463042,netex_zder_quay,463013 +stop_point,MFDI:463042,netex_zder_quay,463042 +stop_point,MFDI:463042,netex_zder_quay,463043 +stop_point,MFDI:463042,netex_zder_quay,monomodalStopPlace:477682 +stop_point,MFDI:463042,source,FR::Quay:463042:FR1 +stop_point,MFDI:426813,netex_monomodal_stopplace,monomodalStopPlace:462743 +stop_point,MFDI:426813,netex_zder_quay,13070 +stop_point,MFDI:426813,netex_zder_quay,13071 +stop_point,MFDI:426813,netex_zder_quay,14651 +stop_point,MFDI:426813,netex_zder_quay,34203 +stop_point,MFDI:426813,netex_zder_quay,35054 +stop_point,MFDI:426813,netex_zder_quay,426791 +stop_point,MFDI:426813,netex_zder_quay,426806 +stop_point,MFDI:426813,netex_zder_quay,426807 +stop_point,MFDI:426813,netex_zder_quay,426812 +stop_point,MFDI:426813,netex_zder_quay,426813 +stop_point,MFDI:426813,netex_zder_quay,426814 +stop_point,MFDI:426813,netex_zder_quay,427388 +stop_point,MFDI:426813,netex_zder_quay,471706 +stop_point,MFDI:426813,netex_zder_quay,477638 +stop_point,MFDI:426813,netex_zder_quay,477718 +stop_point,MFDI:426813,netex_zder_quay,477719 +stop_point,MFDI:426813,netex_zder_quay,485088 +stop_point,MFDI:426813,netex_zder_quay,487504 +stop_point,MFDI:426813,netex_zder_quay,488050 +stop_point,MFDI:426813,netex_zder_quay,488255 +stop_point,MFDI:426813,netex_zder_quay,488256 +stop_point,MFDI:426813,netex_zder_quay,monomodalStopPlace:462743 +stop_point,MFDI:426813,source,FR::Quay:426813:FR1 +stop_point,MFDI:426214,netex_monomodal_stopplace,monomodalStopPlace:57672 +stop_point,MFDI:426214,netex_zder_quay,20300 +stop_point,MFDI:426214,netex_zder_quay,426214 +stop_point,MFDI:426214,netex_zder_quay,monomodalStopPlace:57672 +stop_point,MFDI:426214,source,FR::Quay:426214:FR1 +stop_point,MFDI:477725,netex_monomodal_stopplace,monomodalStopPlace:480958 +stop_point,MFDI:477725,netex_zder_quay,477725 +stop_point,MFDI:477725,netex_zder_quay,monomodalStopPlace:480958 +stop_point,MFDI:477725,source,FR::Quay:477725:FR1 +stop_point,MFDI:34582,netex_monomodal_stopplace,monomodalStopPlace:54733 +stop_point,MFDI:34582,netex_zder_quay,34582 +stop_point,MFDI:34582,netex_zder_quay,34719 +stop_point,MFDI:34582,netex_zder_quay,monomodalStopPlace:54733 +stop_point,MFDI:34582,source,FR::Quay:34582:FR1 +stop_point,MFDI:38175,netex_monomodal_stopplace,monomodalStopPlace:44262 +stop_point,MFDI:38175,netex_zder_quay,38175 +stop_point,MFDI:38175,netex_zder_quay,40739 +stop_point,MFDI:38175,netex_zder_quay,monomodalStopPlace:44262 +stop_point,MFDI:38175,source,FR::Quay:38175:FR1 +stop_point,MFDI:461909,netex_monomodal_stopplace,monomodalStopPlace:473812 +stop_point,MFDI:461909,netex_zder_quay,13497 +stop_point,MFDI:461909,netex_zder_quay,34498 +stop_point,MFDI:461909,netex_zder_quay,34605 +stop_point,MFDI:461909,netex_zder_quay,34610 +stop_point,MFDI:461909,netex_zder_quay,34657 +stop_point,MFDI:461909,netex_zder_quay,34658 +stop_point,MFDI:461909,netex_zder_quay,35033 +stop_point,MFDI:461909,netex_zder_quay,461909 +stop_point,MFDI:461909,netex_zder_quay,481823 +stop_point,MFDI:461909,netex_zder_quay,491803 +stop_point,MFDI:461909,netex_zder_quay,monomodalStopPlace:473812 +stop_point,MFDI:461909,source,FR::Quay:461909:FR1 +stop_point,MFDI:18995,netex_monomodal_stopplace,monomodalStopPlace:57333 +stop_point,MFDI:18995,netex_zder_quay,18995 +stop_point,MFDI:18995,netex_zder_quay,19563 +stop_point,MFDI:18995,netex_zder_quay,monomodalStopPlace:57333 +stop_point,MFDI:18995,source,FR::Quay:18995:FR1 +stop_point,MFDI:34605,netex_monomodal_stopplace,monomodalStopPlace:473812 +stop_point,MFDI:34605,netex_zder_quay,13497 +stop_point,MFDI:34605,netex_zder_quay,34498 +stop_point,MFDI:34605,netex_zder_quay,34605 +stop_point,MFDI:34605,netex_zder_quay,34610 +stop_point,MFDI:34605,netex_zder_quay,34657 +stop_point,MFDI:34605,netex_zder_quay,34658 +stop_point,MFDI:34605,netex_zder_quay,35033 +stop_point,MFDI:34605,netex_zder_quay,461909 +stop_point,MFDI:34605,netex_zder_quay,481823 +stop_point,MFDI:34605,netex_zder_quay,491803 +stop_point,MFDI:34605,netex_zder_quay,monomodalStopPlace:473812 +stop_point,MFDI:34605,source,FR::Quay:34605:FR1 +stop_point,MFDI:34744,netex_monomodal_stopplace,monomodalStopPlace:44620 +stop_point,MFDI:34744,netex_zder_quay,34744 +stop_point,MFDI:34744,netex_zder_quay,34745 +stop_point,MFDI:34744,netex_zder_quay,monomodalStopPlace:44620 +stop_point,MFDI:34744,source,FR::Quay:34744:FR1 +stop_point,MFDI:11584,netex_monomodal_stopplace,monomodalStopPlace:52901 +stop_point,MFDI:11584,netex_zder_quay,11584 +stop_point,MFDI:11584,netex_zder_quay,11585 +stop_point,MFDI:11584,netex_zder_quay,monomodalStopPlace:52901 +stop_point,MFDI:11584,source,FR::Quay:11584:FR1 +stop_point,MFDI:14081,netex_monomodal_stopplace,monomodalStopPlace:45016 +stop_point,MFDI:14081,netex_zder_quay,14081 +stop_point,MFDI:14081,netex_zder_quay,monomodalStopPlace:45016 +stop_point,MFDI:14081,source,FR::Quay:14081:FR1 +stop_point,MFDI:20324,netex_monomodal_stopplace,monomodalStopPlace:57680 +stop_point,MFDI:20324,netex_zder_quay,20324 +stop_point,MFDI:20324,netex_zder_quay,20325 +stop_point,MFDI:20324,netex_zder_quay,monomodalStopPlace:57680 +stop_point,MFDI:20324,source,FR::Quay:20324:FR1 +stop_point,MFDI:20312,netex_monomodal_stopplace,monomodalStopPlace:46420 +stop_point,MFDI:20312,netex_zder_quay,20312 +stop_point,MFDI:20312,netex_zder_quay,20313 +stop_point,MFDI:20312,netex_zder_quay,monomodalStopPlace:46420 +stop_point,MFDI:20312,source,FR::Quay:20312:FR1 +stop_point,MFDI:485179,netex_monomodal_stopplace,monomodalStopPlace:477262 +stop_point,MFDI:485179,netex_zder_quay,477079 +stop_point,MFDI:485179,netex_zder_quay,477080 +stop_point,MFDI:485179,netex_zder_quay,477194 +stop_point,MFDI:485179,netex_zder_quay,477497 +stop_point,MFDI:485179,netex_zder_quay,477499 +stop_point,MFDI:485179,netex_zder_quay,477886 +stop_point,MFDI:485179,netex_zder_quay,479496 +stop_point,MFDI:485179,netex_zder_quay,479497 +stop_point,MFDI:485179,netex_zder_quay,485179 +stop_point,MFDI:485179,netex_zder_quay,491506 +stop_point,MFDI:485179,netex_zder_quay,491507 +stop_point,MFDI:485179,netex_zder_quay,monomodalStopPlace:477262 +stop_point,MFDI:485179,source,FR::Quay:485179:FR1 +network,MFDI:1061,source,FR1:Network:1061:LOC +network,MFDI:1071,source,FR1:Network:1071:LOC +network,MFDI:1062,source,FR1:Network:1062:LOC +network,MFDI:Operator_100,source,FR1:Operator:100:LOC +line,MFDI:C01376,Netex_PrivateCode,100110006 +line,MFDI:C01376,source,FR1:Line:C01376: +line,MFDI:C02060,Netex_PrivateCode,116277010 +line,MFDI:C02060,source,FR1:Line:C02060: +line,MFDI:C02491,Netex_PrivateCode,532532100 +line,MFDI:C02491,source,FR1:Line:C02491: +line,MFDI:C02513,Netex_PrivateCode,000527266 +line,MFDI:C02513,source,FR1:Line:C02513: +route,MFDI:RATP:107494-C01376-ITI_IDFM_C01376_A_-1009412783,Netex_ServiceJourneyPattern,RATP:ServiceJourneyPattern:107494-C01376-MISS_RATP_C01376_-1163221766:LOC +route,MFDI:RATP:107494-C01376-ITI_IDFM_C01376_A_-1009412783,Netex_ServiceJourneyPattern,RATP:ServiceJourneyPattern:107494-C01376-MISS_RATP_C01376_-1646701812:LOC +route,MFDI:RATP:107494-C01376-ITI_IDFM_C01376_A_-1009412783,Netex_ServiceJourneyPattern,RATP:ServiceJourneyPattern:107494-C01376-MISS_RATP_C01376_-1818959048:LOC +route,MFDI:RATP:107494-C01376-ITI_IDFM_C01376_A_-1009412783,Netex_ServiceJourneyPattern,RATP:ServiceJourneyPattern:107494-C01376-MISS_RATP_C01376_1351424965:LOC +route,MFDI:RATP:107494-C01376-ITI_IDFM_C01376_A_-1009412783,source,RATP:Route:107494-C01376-ITI_IDFM_C01376_A_-1009412783:LOC +route,MFDI:KVVB:C02513-SOIR-A,Netex_ServiceJourneyPattern,KVVB:ServiceJourneyPattern:158023-C02513-DWH-C02513-SOIR-A-02:LOC +route,MFDI:KVVB:C02513-SOIR-A,source,KVVB:Route:C02513-SOIR-A:LOC +route,MFDI:BOUCLE_DE_LYS:82336-C02491-4740-ALLER,Netex_ServiceJourneyPattern,BOUCLE_DE_LYS:ServiceJourneyPattern:82336-C02491-41025:LOC +route,MFDI:BOUCLE_DE_LYS:82336-C02491-4740-ALLER,source,BOUCLE_DE_LYS:Route:82336-C02491-4740-ALLER:LOC +route,MFDI:stif:local-153359-C02060-3417,Netex_ServiceJourneyPattern,KRO6:ServiceJourneyPattern:153358-C02060-DWH-C02060-F12-A-02:LOC +route,MFDI:stif:local-153359-C02060-3417,Netex_ServiceJourneyPattern,KRO6:ServiceJourneyPattern:153358-C02060-DWH-C02060-F12-A-03:LOC +route,MFDI:stif:local-153359-C02060-3417,Netex_ServiceJourneyPattern,KRO6:ServiceJourneyPattern:153358-C02060-DWH-C02060-F12-A-06:LOC +route,MFDI:stif:local-153359-C02060-3417,Netex_ServiceJourneyPattern,KRO6:ServiceJourneyPattern:153358-C02060-DWH-C02060-F12-A-07:LOC +route,MFDI:stif:local-153359-C02060-3417,source,stif:Route:local-153359-C02060-3417:LOC +trip,MFDI:KVVB:158023-C02513-1638-260,source,KVVB:ServiceJourney:158023-C02513-1638-260:LOC +trip,MFDI:BOUCLE_DE_LYS:149996-C02491-18777678,source,BOUCLE_DE_LYS:ServiceJourney:149996-C02491-18777678:LOC +trip,MFDI:KRO6:153358-C02060-680-260,source,KRO6:ServiceJourney:153358-C02060-680-260:LOC +trip,MFDI:RATP:153912-C01376-COU_RATP_5086613_2991428_116,source,RATP:ServiceJourney:153912-C01376-COU_RATP_5086613_2991428_116:LOC diff --git a/tests/fixtures/ntfs_with_windows/input/physical_modes.txt b/tests/fixtures/ntfs_with_windows/input/physical_modes.txt new file mode 100644 index 000000000..ddfc1437f --- /dev/null +++ b/tests/fixtures/ntfs_with_windows/input/physical_modes.txt @@ -0,0 +1,6 @@ +physical_mode_id,physical_mode_name,co2_emission +Bus,Bus,92.0 +Metro,Métro,3.8 +Bike,Bike,0.0 +BikeSharingService,BikeSharingService,0.0 +Car,Car,184.0 diff --git a/tests/fixtures/ntfs_with_windows/input/routes.txt b/tests/fixtures/ntfs_with_windows/input/routes.txt new file mode 100644 index 000000000..d46ecfefa --- /dev/null +++ b/tests/fixtures/ntfs_with_windows/input/routes.txt @@ -0,0 +1,5 @@ +route_id,route_name,direction_type,line_id,geometry_id,destination_id +MFDI:RATP:107494-C01376-ITI_IDFM_C01376_A_-1009412783,Charles de Gaulle - Etoile,outbound,MFDI:C01376,,MFDI:71347 +MFDI:KVVB:C02513-SOIR-A,Porte Jaune,outbound,MFDI:C02513,,MFDI:63534 +MFDI:BOUCLE_DE_LYS:82336-C02491-4740-ALLER,Gare de St-Germain-en-Laye - Gare Routière,inbound,MFDI:C02491,,MFDI:64589 +MFDI:stif:local-153359-C02060-3417,Gare de Roissypole Aéroport CDG 1,outbound,MFDI:C02060,,MFDI:73596 diff --git a/tests/fixtures/ntfs_with_windows/input/stop_times.txt b/tests/fixtures/ntfs_with_windows/input/stop_times.txt new file mode 100644 index 000000000..af3d61dc2 --- /dev/null +++ b/tests/fixtures/ntfs_with_windows/input/stop_times.txt @@ -0,0 +1,21 @@ +stop_id,trip_id,stop_sequence,arrival_time,departure_time,start_pickup_drop_off_window,end_pickup_drop_off_window,boarding_duration,alighting_duration,pickup_type,drop_off_type,local_zone_id,stop_headsign,stop_time_id,stop_time_precision +MFDI:485179,MFDI:KVVB:158023-C02513-1638-260,0,22:30:00,22:30:00,,,0,0,2,1,,,,0 +MFDI:426214,MFDI:KVVB:158023-C02513-1638-260,1,,,22:36:00,22:55:00,0,0,1,2,,,,2 +MFDI:20312,MFDI:KVVB:158023-C02513-1638-260,12,,,22:36:00,22:55:00,0,0,1,2,,,,2 +MFDI:20324,MFDI:KVVB:158023-C02513-1638-260,24,,,22:36:00,22:55:00,0,0,1,2,,,,2 +MFDI:11584,MFDI:KVVB:158023-C02513-1638-260,32,,,22:36:00,22:55:00,0,0,1,2,,,,2 +MFDI:34605,MFDI:BOUCLE_DE_LYS:149996-C02491-18777678,0,,,23:15:00,23:48:00,0,0,2,1,,,,2 +MFDI:34744,MFDI:BOUCLE_DE_LYS:149996-C02491-18777678,1,,,23:15:00,23:48:00,0,0,2,2,,,,2 +MFDI:14081,MFDI:BOUCLE_DE_LYS:149996-C02491-18777678,15,,,23:15:00,23:48:00,0,0,2,2,,,,2 +MFDI:34582,MFDI:BOUCLE_DE_LYS:149996-C02491-18777678,25,,,23:15:00,23:48:00,0,0,2,2,,,,2 +MFDI:461909,MFDI:BOUCLE_DE_LYS:149996-C02491-18777678,35,,,23:15:00,23:48:00,0,0,1,2,,,,2 +MFDI:477725,MFDI:KRO6:153358-C02060-680-260,0,26:39:00,26:39:00,,,0,0,2,1,,,,0 +MFDI:38175,MFDI:KRO6:153358-C02060-680-260,1,26:40:00,26:40:00,,,0,0,2,2,,,,0 +MFDI:18995,MFDI:KRO6:153358-C02060-680-260,17,26:52:00,26:52:00,,,0,0,2,2,,,,0 +MFDI:41403,MFDI:KRO6:153358-C02060-680-260,32,27:06:00,27:06:00,,,0,0,2,2,,,,0 +MFDI:426813,MFDI:KRO6:153358-C02060-680-260,37,27:15:00,27:15:00,,,0,0,1,2,,,,0 +MFDI:22073,MFDI:RATP:153912-C01376-COU_RATP_5086613_2991428_116,0,10:30:00,10:30:00,,,0,0,0,1,,,,0 +MFDI:22167,MFDI:RATP:153912-C01376-COU_RATP_5086613_2991428_116,1,10:31:00,10:31:00,,,0,0,0,0,,,,0 +MFDI:22173,MFDI:RATP:153912-C01376-COU_RATP_5086613_2991428_116,11,10:43:00,10:43:00,,,0,0,0,0,,,,0 +MFDI:463194,MFDI:RATP:153912-C01376-COU_RATP_5086613_2991428_116,20,10:54:00,10:54:00,,,0,0,0,0,,,,0 +MFDI:463042,MFDI:RATP:153912-C01376-COU_RATP_5086613_2991428_116,27,11:03:00,11:03:00,,,0,0,1,0,,,,0 diff --git a/tests/fixtures/ntfs_with_windows/input/stops.txt b/tests/fixtures/ntfs_with_windows/input/stops.txt new file mode 100644 index 000000000..fda37a803 --- /dev/null +++ b/tests/fixtures/ntfs_with_windows/input/stops.txt @@ -0,0 +1,40 @@ +stop_id,stop_name,stop_code,visible,fare_zone_id,stop_lon,stop_lat,location_type,parent_station,stop_timezone,geometry_id,equipment_id,level_id,platform_code,address_id +MFDI:22167,Picpus,,1,1,2.401248269453829,48.84501767720269,0,MFDI:71639,Europe/Paris,,MFDI:3,,, +MFDI:22173,Glacière,,1,1,2.3434974927179884,48.831170235245835,0,MFDI:71026,Europe/Paris,,MFDI:3,,, +MFDI:22073,Nation,,1,1,2.3958598043279085,48.84789550545761,0,MFDI:71673,Europe/Paris,,MFDI:3,,, +MFDI:41403,Cargo Centre,,1,5,2.526990016633599,48.99817129747993,0,MFDI:73591,Europe/Paris,,MFDI:1,,, +MFDI:463194,La Motte-Picquet - Grenelle,,1,1,2.298957096977008,48.848765448122315,0,MFDI:71199,Europe/Paris,,MFDI:3,,, +MFDI:463042,Charles de Gaulle - Etoile,,1,1,2.2947520493673434,48.87371127132366,0,MFDI:71347,Europe/Paris,,MFDI:3,,, +MFDI:426813,Gare de Roissypole - Aéroport CDG1 Terminal 3 (C4),,1,,2.559069276593061,49.010290004685544,0,MFDI:73596,Europe/Paris,,MFDI:2,,, +MFDI:426214,La Logeraie,,1,4,2.1359934967138585,48.766289059613705,0,MFDI:63529,Europe/Paris,,MFDI:1,,, +MFDI:477725,Verdi,,1,4,2.577391101137773,48.961194121418,0,MFDI:480959,Europe/Paris,,MFDI:2,,, +MFDI:34582,Fourqueux,,1,,2.0804267048554177,48.89058561987773,0,MFDI:64509,Europe/Paris,,MFDI:1,,, +MFDI:38175,Parmentier,,1,4,2.561581492140883,48.947693512717194,0,MFDI:73486,Europe/Paris,,MFDI:2,,, +MFDI:461909,Gare de Saint-Germain-en-Laye,,1,,2.094588526727687,48.898931576292874,0,MFDI:64589,Europe/Paris,,MFDI:1,,, +MFDI:18995,Croix l'Aumône,,1,4,2.524710804326184,48.96497157469924,0,MFDI:73556,Europe/Paris,,MFDI:2,,, +MFDI:34605,Gare de Saint-Germain-en-Laye,,1,,2.0939283750483924,48.89924135453759,0,MFDI:64589,Europe/Paris,,MFDI:1,,, +MFDI:34744,République,,1,,2.0927460449808457,48.89812620815719,0,MFDI:426072,Europe/Paris,,MFDI:1,,, +MFDI:11584,Porte Jaune,,1,4,2.229129261380777,48.76610796421317,0,MFDI:63534,Europe/Paris,,MFDI:1,,, +MFDI:14081,Victor Hugo,,1,,2.063504165681303,48.886623198199004,0,MFDI:64485,Europe/Paris,,MFDI:2,,, +MFDI:20324,Clos Normand,,1,4,2.186312472329811,48.75818767629223,0,MFDI:63438,Europe/Paris,,MFDI:1,,, +MFDI:20312,Les Tilleuls,,1,4,2.1615499577506054,48.76517599148135,0,MFDI:461827,Europe/Paris,,MFDI:2,,, +MFDI:485179,Gare routière de Versailles Chantiers - Quai G,,1,4,2.1340608589561016,48.795848498088226,0,MFDI:63880,Europe/Paris,,MFDI:1,,, +MFDI:461827,Les Tilleuls,,1,,2.1613451720416506,48.76521952597488,1,,,,,,, +MFDI:426072,République / Rue de la Salle,,1,,2.092660713832334,48.89762192758876,1,,,,,,, +MFDI:71639,Picpus,,1,,2.402166806721031,48.845125696754025,1,,,,,,, +MFDI:71673,Nation,,1,,2.3963316057344417,48.848927647042316,1,,,,,,, +MFDI:64589,Saint-Germain-en-Laye,,1,,2.0951814549394174,48.899349756253876,1,,,,,,, +MFDI:63880,Versailles Chantiers,,1,,2.134652391388478,48.79588875952142,1,,,,,,, +MFDI:71026,Glacière,,1,,2.3438687884909264,48.8308934672617,1,,,,,,, +MFDI:64509,Fourqueux,,1,,2.080767458510045,48.89098395203159,1,,,,,,, +MFDI:64485,Victor Hugo,,1,,2.063504165681303,48.886623198199004,1,,,,,,, +MFDI:63534,Porte Jaune,,1,,2.2291546111332714,48.766234048830825,1,,,,,,, +MFDI:63529,La Logeraie,,1,,2.1363481054691924,48.76623765829017,1,,,,,,, +MFDI:63438,Clos Normand,,1,,2.1861969917891195,48.758177894949306,1,,,,,,, +MFDI:73556,Croix l'Aumône,,1,,2.524833265434999,48.965021518604,1,,,,,,, +MFDI:73596,Roissy Aéroport CDG 1 (Terminal 3) (Tremblay-en-France),,1,,2.5601295519817535,49.01033329803776,1,,,,,,, +MFDI:73591,Cargo Centre,,1,,2.5261341855607036,48.998356758085166,1,,,,,,, +MFDI:71347,Charles de Gaulle - Etoile,,1,,2.2946168784613463,48.87362503818625,1,,,,,,, +MFDI:73486,Parmentier / Saint Vincent de Paul,,1,,2.5608350156242676,48.94635987507931,1,,,,,,, +MFDI:71199,La Motte-Picquet - Grenelle,,1,,2.2984077121284154,48.84918377697637,1,,,,,,, +MFDI:480959,Verdi,,1,,2.577391101137773,48.961194121418,1,,,,,,, diff --git a/tests/fixtures/ntfs_with_windows/input/transfers.txt b/tests/fixtures/ntfs_with_windows/input/transfers.txt new file mode 100644 index 000000000..fd6cdd54d --- /dev/null +++ b/tests/fixtures/ntfs_with_windows/input/transfers.txt @@ -0,0 +1,27 @@ +from_stop_id,to_stop_id,min_transfer_time,real_min_transfer_time,equipment_id +MFDI:22167,MFDI:22167,0,120, +MFDI:20324,MFDI:20324,0,120, +MFDI:34744,MFDI:461909,206,326, +MFDI:34582,MFDI:34582,0,120, +MFDI:34744,MFDI:34744,0,120, +MFDI:463042,MFDI:463042,0,120, +MFDI:34744,MFDI:34605,192,312, +MFDI:22173,MFDI:22173,0,120, +MFDI:11584,MFDI:11584,0,120, +MFDI:18995,MFDI:18995,0,120, +MFDI:22073,MFDI:22073,0,120, +MFDI:14081,MFDI:14081,0,120, +MFDI:20312,MFDI:20312,0,120, +MFDI:426214,MFDI:426214,0,120, +MFDI:34605,MFDI:34605,0,120, +MFDI:34605,MFDI:34744,192,312, +MFDI:461909,MFDI:461909,0,120, +MFDI:461909,MFDI:34744,206,326, +MFDI:38175,MFDI:38175,0,120, +MFDI:461909,MFDI:34605,62,242, +MFDI:477725,MFDI:477725,0,120, +MFDI:426813,MFDI:426813,0,120, +MFDI:463194,MFDI:463194,0,120, +MFDI:485179,MFDI:485179,0,120, +MFDI:41403,MFDI:41403,0,120, +MFDI:34605,MFDI:461909,62,242, diff --git a/tests/fixtures/ntfs_with_windows/input/trip_properties.txt b/tests/fixtures/ntfs_with_windows/input/trip_properties.txt new file mode 100644 index 000000000..79edeaf85 --- /dev/null +++ b/tests/fixtures/ntfs_with_windows/input/trip_properties.txt @@ -0,0 +1,5 @@ +trip_property_id,wheelchair_accessible,bike_accepted,air_conditioned,visual_announcement,audible_announcement,appropriate_escort,appropriate_signage,school_vehicle_type +MFDI:3,0,0,0,0,0,0,0,0 +MFDI:5,0,0,0,1,1,0,0,0 +MFDI:7,2,0,0,0,0,0,0,0 +MFDI:9,0,0,0,2,2,0,0,0 diff --git a/tests/fixtures/ntfs_with_windows/input/trips.txt b/tests/fixtures/ntfs_with_windows/input/trips.txt new file mode 100644 index 000000000..7f616404e --- /dev/null +++ b/tests/fixtures/ntfs_with_windows/input/trips.txt @@ -0,0 +1,5 @@ +trip_id,route_id,physical_mode_id,dataset_id,service_id,trip_headsign,trip_short_name,block_id,company_id,trip_property_id,geometry_id,journey_pattern_id +MFDI:KVVB:158023-C02513-1638-260,MFDI:KVVB:C02513-SOIR-A,Bus,MFDI:4c649e1d-f7e4-4622-b6df-30e0997704af,MFDI:1000,Porte Jaune,,,MFDI:1017,MFDI:5,, +MFDI:BOUCLE_DE_LYS:149996-C02491-18777678,MFDI:BOUCLE_DE_LYS:82336-C02491-4740-ALLER,Bus,MFDI:4c649e1d-f7e4-4622-b6df-30e0997704af,MFDI:1,Gare de St-Germain-en-Laye - Gare Routière,,,MFDI:1021,MFDI:3,, +MFDI:KRO6:153358-C02060-680-260,MFDI:stif:local-153359-C02060-3417,Bus,MFDI:4c649e1d-f7e4-4622-b6df-30e0997704af,MFDI:1000,Gare de Roissypole Aéroport CDG 1,,,MFDI:1028,MFDI:9,, +MFDI:RATP:153912-C01376-COU_RATP_5086613_2991428_116,MFDI:RATP:107494-C01376-ITI_IDFM_C01376_A_-1009412783,Metro,MFDI:4c649e1d-f7e4-4622-b6df-30e0997704af,MFDI:1,Charles de Gaulle-Etoile,,,MFDI:100,MFDI:7,, diff --git a/tests/fixtures/ntfs_with_windows/output/stop_times.txt b/tests/fixtures/ntfs_with_windows/output/stop_times.txt new file mode 100644 index 000000000..af3d61dc2 --- /dev/null +++ b/tests/fixtures/ntfs_with_windows/output/stop_times.txt @@ -0,0 +1,21 @@ +stop_id,trip_id,stop_sequence,arrival_time,departure_time,start_pickup_drop_off_window,end_pickup_drop_off_window,boarding_duration,alighting_duration,pickup_type,drop_off_type,local_zone_id,stop_headsign,stop_time_id,stop_time_precision +MFDI:485179,MFDI:KVVB:158023-C02513-1638-260,0,22:30:00,22:30:00,,,0,0,2,1,,,,0 +MFDI:426214,MFDI:KVVB:158023-C02513-1638-260,1,,,22:36:00,22:55:00,0,0,1,2,,,,2 +MFDI:20312,MFDI:KVVB:158023-C02513-1638-260,12,,,22:36:00,22:55:00,0,0,1,2,,,,2 +MFDI:20324,MFDI:KVVB:158023-C02513-1638-260,24,,,22:36:00,22:55:00,0,0,1,2,,,,2 +MFDI:11584,MFDI:KVVB:158023-C02513-1638-260,32,,,22:36:00,22:55:00,0,0,1,2,,,,2 +MFDI:34605,MFDI:BOUCLE_DE_LYS:149996-C02491-18777678,0,,,23:15:00,23:48:00,0,0,2,1,,,,2 +MFDI:34744,MFDI:BOUCLE_DE_LYS:149996-C02491-18777678,1,,,23:15:00,23:48:00,0,0,2,2,,,,2 +MFDI:14081,MFDI:BOUCLE_DE_LYS:149996-C02491-18777678,15,,,23:15:00,23:48:00,0,0,2,2,,,,2 +MFDI:34582,MFDI:BOUCLE_DE_LYS:149996-C02491-18777678,25,,,23:15:00,23:48:00,0,0,2,2,,,,2 +MFDI:461909,MFDI:BOUCLE_DE_LYS:149996-C02491-18777678,35,,,23:15:00,23:48:00,0,0,1,2,,,,2 +MFDI:477725,MFDI:KRO6:153358-C02060-680-260,0,26:39:00,26:39:00,,,0,0,2,1,,,,0 +MFDI:38175,MFDI:KRO6:153358-C02060-680-260,1,26:40:00,26:40:00,,,0,0,2,2,,,,0 +MFDI:18995,MFDI:KRO6:153358-C02060-680-260,17,26:52:00,26:52:00,,,0,0,2,2,,,,0 +MFDI:41403,MFDI:KRO6:153358-C02060-680-260,32,27:06:00,27:06:00,,,0,0,2,2,,,,0 +MFDI:426813,MFDI:KRO6:153358-C02060-680-260,37,27:15:00,27:15:00,,,0,0,1,2,,,,0 +MFDI:22073,MFDI:RATP:153912-C01376-COU_RATP_5086613_2991428_116,0,10:30:00,10:30:00,,,0,0,0,1,,,,0 +MFDI:22167,MFDI:RATP:153912-C01376-COU_RATP_5086613_2991428_116,1,10:31:00,10:31:00,,,0,0,0,0,,,,0 +MFDI:22173,MFDI:RATP:153912-C01376-COU_RATP_5086613_2991428_116,11,10:43:00,10:43:00,,,0,0,0,0,,,,0 +MFDI:463194,MFDI:RATP:153912-C01376-COU_RATP_5086613_2991428_116,20,10:54:00,10:54:00,,,0,0,0,0,,,,0 +MFDI:463042,MFDI:RATP:153912-C01376-COU_RATP_5086613_2991428_116,27,11:03:00,11:03:00,,,0,0,1,0,,,,0 diff --git a/tests/read_ntfs.rs b/tests/read_ntfs.rs index 79dff2743..d76db1548 100644 --- a/tests/read_ntfs.rs +++ b/tests/read_ntfs.rs @@ -556,3 +556,16 @@ fn ntfs_with_duplicated_objects_without_id() { assert_eq!(1, model.grid_periods.len()); assert_eq!(2, model.grid_rel_calendar_line.len()); } + +#[test] +fn preserve_stoptimes_windows() { + let ntm = transit_model::ntfs::read("tests/fixtures/ntfs_with_windows/input/").unwrap(); + test_in_tmp_dir(|output_dir| { + transit_model::ntfs::write(&ntm, output_dir, get_test_datetime()).unwrap(); + compare_output_dir_with_expected( + output_dir, + Some(vec!["stop_times.txt"]), + "tests/fixtures/ntfs_with_windows/output", + ); + }); +}