-
Notifications
You must be signed in to change notification settings - Fork 100
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'master' into 1640-add-GtfsNetworkSchema
- Loading branch information
Showing
2 changed files
with
0 additions
and
122 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -68,58 +68,6 @@ private void validateSpecFeature( | |
} | ||
} | ||
|
||
@Test | ||
public void containsRouteNamesComponentTest() throws IOException, InterruptedException { | ||
String routesContent = | ||
"route_id,agency_id,route_short_name,route_long_name,route_type\n" | ||
+ "1,1,Short Name,Long Name,1\n" | ||
+ "2,1,,,1\n"; | ||
createDataFile("routes.txt", routesContent); | ||
validateSpecFeature( | ||
"Route Names", | ||
true, | ||
ImmutableList.of(GtfsRouteTableDescriptor.class, GtfsAgencyTableDescriptor.class)); | ||
} | ||
|
||
@Test | ||
public void omitsRouteNamesComponentTest1() throws IOException, InterruptedException { | ||
String routesContent = | ||
"route_id,agency_id,route_short_name,route_long_name,route_type\n" | ||
+ "1,1,,,1\n" | ||
+ "2,1,,,1\n"; | ||
createDataFile("routes.txt", routesContent); | ||
validateSpecFeature( | ||
"Route Names", | ||
false, | ||
ImmutableList.of(GtfsRouteTableDescriptor.class, GtfsAgencyTableDescriptor.class)); | ||
} | ||
|
||
@Test | ||
public void omitsRouteNamesComponentTest2() throws IOException, InterruptedException { | ||
String routesContent = | ||
"route_id,agency_id,route_short_name,route_long_name,route_type\n" | ||
+ "1,1,Short Name,,1\n" | ||
+ "2,1,,,1\n"; | ||
createDataFile("routes.txt", routesContent); | ||
validateSpecFeature( | ||
"Route Names", | ||
false, | ||
ImmutableList.of(GtfsRouteTableDescriptor.class, GtfsAgencyTableDescriptor.class)); | ||
} | ||
|
||
@Test | ||
public void omitsRouteNamesComponentTest3() throws IOException, InterruptedException { | ||
String routesContent = | ||
"route_id,agency_id,route_short_name,route_long_name,route_type\n" | ||
+ "1,1,,Long Name,1\n" | ||
+ "2,1,,,1\n"; | ||
createDataFile("routes.txt", routesContent); | ||
validateSpecFeature( | ||
"Route Names", | ||
false, | ||
ImmutableList.of(GtfsRouteTableDescriptor.class, GtfsAgencyTableDescriptor.class)); | ||
} | ||
|
||
@Test | ||
/** | ||
* This method is to test when both route_color and route_text_color are present in routes.txt, | ||
|
@@ -248,10 +196,6 @@ public void omitsComponents() throws IOException, InterruptedException { | |
"Pathways (basic)", | ||
false, | ||
ImmutableList.of(GtfsPathwayTableDescriptor.class, GtfsAgencyTableDescriptor.class)); | ||
validateSpecFeature( | ||
"Route Names", | ||
false, | ||
ImmutableList.of(GtfsRouteTableDescriptor.class, GtfsAgencyTableDescriptor.class)); | ||
validateSpecFeature( | ||
"Shapes", | ||
false, | ||
|
@@ -423,48 +367,6 @@ public void omitsZoneBasedFaresComponentTest() throws IOException, InterruptedEx | |
ImmutableList.of(GtfsStopAreaTableDescriptor.class, GtfsAgencyTableDescriptor.class)); | ||
} | ||
|
||
@Test | ||
public void containsAgencyInformationComponent() throws IOException, InterruptedException { | ||
tmpDir.delete(); | ||
rootDir = tmpDir.newFolder("data"); | ||
String agencyContent = | ||
"agency_id, agency_name, agency_url, agency_timezone, agency_phone, agency_email\n" | ||
+ "1, name, https://dummy.ca, America/Los_Angeles, 1234567890, [email protected]\n"; | ||
createDataFile(GtfsAgency.FILENAME, agencyContent); | ||
validateSpecFeature( | ||
"Agency Information", true, ImmutableList.of(GtfsAgencyTableDescriptor.class)); | ||
} | ||
|
||
@Test | ||
public void omitsAgencyInformationComponent1() throws IOException, InterruptedException { | ||
tmpDir.delete(); | ||
rootDir = tmpDir.newFolder("data"); | ||
String agencyContent = | ||
"agency_id, agency_name, agency_url, agency_timezone, agency_phone, agency_email\n" | ||
+ "1, name, https://dummy.ca, America/Los_Angeles, , [email protected]\n"; | ||
createDataFile(GtfsAgency.FILENAME, agencyContent); | ||
validateSpecFeature( | ||
"Agency Information", false, ImmutableList.of(GtfsAgencyTableDescriptor.class)); | ||
} | ||
|
||
@Test | ||
public void omitsAgencyInformationComponent2() throws IOException, InterruptedException { | ||
tmpDir.delete(); | ||
rootDir = tmpDir.newFolder("data"); | ||
String agencyContent = | ||
"agency_id, agency_name, agency_url, agency_timezone, agency_phone, agency_email\n" | ||
+ "1, name, https://dummy.ca, America/Los_Angeles, 1234567890, \n"; | ||
createDataFile(GtfsAgency.FILENAME, agencyContent); | ||
validateSpecFeature( | ||
"Agency Information", false, ImmutableList.of(GtfsAgencyTableDescriptor.class)); | ||
} | ||
|
||
@Test | ||
public void omitsAgencyInformationComponent3() throws IOException, InterruptedException { | ||
validateSpecFeature( | ||
"Agency Information", false, ImmutableList.of(GtfsAgencyTableDescriptor.class)); | ||
} | ||
|
||
@Test | ||
public void containsHeadsignsComponent1() throws IOException, InterruptedException { | ||
String content = "route_id, service_id, trip_id, trip_headsign\n" + "1, 2, 3, headsign_dummy\n"; | ||
|