connection test for each provider

git-svn-id: https://public-transport-enabler.googlecode.com/svn/trunk@671 0924bc21-9374-b0fa-ee44-9ff1593b38f0
This commit is contained in:
andreas.schildbach@gmail.com 2011-05-31 07:37:20 +00:00
parent 9347abb973
commit bb7ce58ca2
37 changed files with 504 additions and 3 deletions

View file

@ -17,14 +17,17 @@
package de.schildbach.pte.live;
import java.util.Date;
import java.util.List;
import org.junit.Test;
import de.schildbach.pte.AtcProvider;
import de.schildbach.pte.NetworkProvider.WalkSpeed;
import de.schildbach.pte.dto.Location;
import de.schildbach.pte.dto.LocationType;
import de.schildbach.pte.dto.NearbyStationsResult;
import de.schildbach.pte.dto.QueryConnectionsResult;
import de.schildbach.pte.dto.QueryDeparturesResult;
/**
@ -33,6 +36,7 @@ import de.schildbach.pte.dto.QueryDeparturesResult;
public class AtcProviderLiveTest
{
private final AtcProvider provider = new AtcProvider();
private static final String ALL_PRODUCTS = "IRSUTBFC";
@Test
public void nearbyStations() throws Exception
@ -74,4 +78,14 @@ public class AtcProviderLiveTest
System.out.print(autocomplete.toDebugString() + " ");
System.out.println();
}
@Test
public void shortConnection() throws Exception
{
final QueryConnectionsResult result = provider.queryConnections(new Location(LocationType.STATION, 0, null, "Hauptwache"), null,
new Location(LocationType.STATION, 0, null, "Südbahnhof"), new Date(), true, ALL_PRODUCTS, WalkSpeed.NORMAL);
System.out.println(result);
final QueryConnectionsResult moreResult = provider.queryMoreConnections(result.context);
System.out.println(moreResult);
}
}

View file

@ -17,14 +17,17 @@
package de.schildbach.pte.live;
import java.util.Date;
import java.util.List;
import org.junit.Test;
import de.schildbach.pte.AvvProvider;
import de.schildbach.pte.NetworkProvider.WalkSpeed;
import de.schildbach.pte.dto.Location;
import de.schildbach.pte.dto.LocationType;
import de.schildbach.pte.dto.NearbyStationsResult;
import de.schildbach.pte.dto.QueryConnectionsResult;
import de.schildbach.pte.dto.QueryDeparturesResult;
/**
@ -33,6 +36,7 @@ import de.schildbach.pte.dto.QueryDeparturesResult;
public class AvvProviderLiveTest
{
private final AvvProvider provider = new AvvProvider();
private static final String ALL_PRODUCTS = "IRSUTBFC";
@Test
public void nearbyStations() throws Exception
@ -73,4 +77,14 @@ public class AvvProviderLiveTest
System.out.print(autocomplete.toDebugString() + " ");
System.out.println();
}
@Test
public void shortConnection() throws Exception
{
final QueryConnectionsResult result = provider.queryConnections(new Location(LocationType.STATION, 101, null, "Königsplatz"), null,
new Location(LocationType.STATION, 100, null, "Hauptbahnhof"), new Date(), true, ALL_PRODUCTS, WalkSpeed.NORMAL);
System.out.println(result);
final QueryConnectionsResult moreResult = provider.queryMoreConnections(result.context);
System.out.println(moreResult);
}
}

View file

@ -17,14 +17,17 @@
package de.schildbach.pte.live;
import java.util.Date;
import java.util.List;
import org.junit.Test;
import de.schildbach.pte.BsagProvider;
import de.schildbach.pte.NetworkProvider.WalkSpeed;
import de.schildbach.pte.dto.Location;
import de.schildbach.pte.dto.LocationType;
import de.schildbach.pte.dto.NearbyStationsResult;
import de.schildbach.pte.dto.QueryConnectionsResult;
/**
* @author Andreas Schildbach
@ -32,6 +35,7 @@ import de.schildbach.pte.dto.NearbyStationsResult;
public class BsagProviderLiveTest
{
private final BsagProvider provider = new BsagProvider();
private static final String ALL_PRODUCTS = "IRSUTBFC";
@Test
public void nearbyStations() throws Exception
@ -64,4 +68,14 @@ public class BsagProviderLiveTest
System.out.print(autocomplete.toDebugString() + " ");
System.out.println();
}
@Test
public void shortConnection() throws Exception
{
final QueryConnectionsResult result = provider.queryConnections(new Location(LocationType.STATION, 28000257, null, "Bremen, Hauptbahnhof"),
null, new Location(LocationType.STATION, 28000512, null, "Herdentor"), new Date(), true, ALL_PRODUCTS, WalkSpeed.NORMAL);
System.out.println(result);
final QueryConnectionsResult moreResult = provider.queryMoreConnections(result.context);
System.out.println(moreResult);
}
}

View file

@ -17,14 +17,17 @@
package de.schildbach.pte.live;
import java.util.Date;
import java.util.List;
import org.junit.Test;
import de.schildbach.pte.BsvagProvider;
import de.schildbach.pte.NetworkProvider.WalkSpeed;
import de.schildbach.pte.dto.Location;
import de.schildbach.pte.dto.LocationType;
import de.schildbach.pte.dto.NearbyStationsResult;
import de.schildbach.pte.dto.QueryConnectionsResult;
/**
* @author Andreas Schildbach
@ -32,6 +35,7 @@ import de.schildbach.pte.dto.NearbyStationsResult;
public class BsvagProviderLiveTest
{
private final BsvagProvider provider = new BsvagProvider();
private static final String ALL_PRODUCTS = "IRSUTBFC";
@Test
public void nearbyStations() throws Exception
@ -64,4 +68,14 @@ public class BsvagProviderLiveTest
System.out.print(autocomplete.toDebugString() + " ");
System.out.println();
}
@Test
public void shortConnection() throws Exception
{
final QueryConnectionsResult result = provider.queryConnections(new Location(LocationType.STATION, 26000178, null, "Hauptbahnhof"), null,
new Location(LocationType.STATION, 26000322, null, "Packhof"), new Date(), true, ALL_PRODUCTS, WalkSpeed.NORMAL);
System.out.println(result);
final QueryConnectionsResult moreResult = provider.queryMoreConnections(result.context);
System.out.println(moreResult);
}
}

View file

@ -17,14 +17,17 @@
package de.schildbach.pte.live;
import java.util.Date;
import java.util.List;
import org.junit.Test;
import de.schildbach.pte.BvbProvider;
import de.schildbach.pte.NetworkProvider.WalkSpeed;
import de.schildbach.pte.dto.Location;
import de.schildbach.pte.dto.LocationType;
import de.schildbach.pte.dto.NearbyStationsResult;
import de.schildbach.pte.dto.QueryConnectionsResult;
import de.schildbach.pte.dto.QueryDeparturesResult;
/**
@ -33,6 +36,7 @@ import de.schildbach.pte.dto.QueryDeparturesResult;
public class BvbProviderLiveTest
{
private final BvbProvider provider = new BvbProvider();
private static final String ALL_PRODUCTS = "IRSUTBFC";
@Test
public void nearbyStations() throws Exception
@ -73,4 +77,14 @@ public class BvbProviderLiveTest
System.out.print(autocomplete.toDebugString() + " ");
System.out.println();
}
@Test
public void shortConnection() throws Exception
{
final QueryConnectionsResult result = provider.queryConnections(new Location(LocationType.STATION, 10000, null, "Bahnhof"), null,
new Location(LocationType.STATION, 86, null, "Markthalle"), new Date(), true, ALL_PRODUCTS, WalkSpeed.NORMAL);
System.out.println(result);
final QueryConnectionsResult moreResult = provider.queryMoreConnections(result.context);
System.out.println(moreResult);
}
}

View file

@ -17,14 +17,17 @@
package de.schildbach.pte.live;
import java.util.Date;
import java.util.List;
import org.junit.Test;
import de.schildbach.pte.DingProvider;
import de.schildbach.pte.NetworkProvider.WalkSpeed;
import de.schildbach.pte.dto.Location;
import de.schildbach.pte.dto.LocationType;
import de.schildbach.pte.dto.NearbyStationsResult;
import de.schildbach.pte.dto.QueryConnectionsResult;
import de.schildbach.pte.dto.QueryDeparturesResult;
/**
@ -33,6 +36,7 @@ import de.schildbach.pte.dto.QueryDeparturesResult;
public class DingProviderLiveTest
{
private final DingProvider provider = new DingProvider();
private static final String ALL_PRODUCTS = "IRSUTBFC";
@Test
public void nearbyStations() throws Exception
@ -73,4 +77,14 @@ public class DingProviderLiveTest
System.out.print(autocomplete.toDebugString() + " ");
System.out.println();
}
@Test
public void shortConnection() throws Exception
{
final QueryConnectionsResult result = provider.queryConnections(new Location(LocationType.STATION, 9001011, null, "Justizgebäude"), null,
new Location(LocationType.STATION, 2504524, null, "Theater"), new Date(), true, ALL_PRODUCTS, WalkSpeed.NORMAL);
System.out.println(result);
final QueryConnectionsResult moreResult = provider.queryMoreConnections(result.context);
System.out.println(moreResult);
}
}

View file

@ -17,14 +17,17 @@
package de.schildbach.pte.live;
import java.util.Date;
import java.util.List;
import org.junit.Test;
import de.schildbach.pte.DsbProvider;
import de.schildbach.pte.NetworkProvider.WalkSpeed;
import de.schildbach.pte.dto.Location;
import de.schildbach.pte.dto.LocationType;
import de.schildbach.pte.dto.NearbyStationsResult;
import de.schildbach.pte.dto.QueryConnectionsResult;
import de.schildbach.pte.dto.QueryDeparturesResult;
/**
@ -33,6 +36,7 @@ import de.schildbach.pte.dto.QueryDeparturesResult;
public class DsbProviderLiveTest
{
private final DsbProvider provider = new DsbProvider();
private static final String ALL_PRODUCTS = "IRSUTBFC";
@Test
public void nearbyStations() throws Exception
@ -73,4 +77,14 @@ public class DsbProviderLiveTest
System.out.print(autocomplete.toDebugString() + " ");
System.out.println();
}
@Test
public void shortConnection() throws Exception
{
final QueryConnectionsResult result = provider.queryConnections(new Location(LocationType.STATION, 900000011, null, "Copenhagen Airport"),
null, new Location(LocationType.STATION, 551922500, null, "Billund Airport"), new Date(), true, ALL_PRODUCTS, WalkSpeed.NORMAL);
System.out.println(result);
final QueryConnectionsResult moreResult = provider.queryMoreConnections(result.context);
System.out.println(moreResult);
}
}

View file

@ -17,14 +17,17 @@
package de.schildbach.pte.live;
import java.util.Date;
import java.util.List;
import org.junit.Test;
import de.schildbach.pte.DubProvider;
import de.schildbach.pte.NetworkProvider.WalkSpeed;
import de.schildbach.pte.dto.Location;
import de.schildbach.pte.dto.LocationType;
import de.schildbach.pte.dto.NearbyStationsResult;
import de.schildbach.pte.dto.QueryConnectionsResult;
/**
* @author Andreas Schildbach
@ -32,6 +35,7 @@ import de.schildbach.pte.dto.NearbyStationsResult;
public class DubProviderLiveTest
{
private final DubProvider provider = new DubProvider();
private static final String ALL_PRODUCTS = "IRSUTBFC";
@Test
public void nearbyStations() throws Exception
@ -64,4 +68,15 @@ public class DubProviderLiveTest
System.out.print(autocomplete.toDebugString() + " ");
System.out.println();
}
@Test
public void shortConnection() throws Exception
{
final QueryConnectionsResult result = provider.queryConnections(new Location(LocationType.STATION, 3505565, null,
"Airport Terminal 1, Arrival"), null, new Location(LocationType.STATION, 3505445, null, "Airport Terminal 3"), new Date(), true,
ALL_PRODUCTS, WalkSpeed.NORMAL);
System.out.println(result);
final QueryConnectionsResult moreResult = provider.queryMoreConnections(result.context);
System.out.println(moreResult);
}
}

View file

@ -17,14 +17,17 @@
package de.schildbach.pte.live;
import java.util.Date;
import java.util.List;
import org.junit.Test;
import de.schildbach.pte.IvbProvider;
import de.schildbach.pte.NetworkProvider.WalkSpeed;
import de.schildbach.pte.dto.Location;
import de.schildbach.pte.dto.LocationType;
import de.schildbach.pte.dto.NearbyStationsResult;
import de.schildbach.pte.dto.QueryConnectionsResult;
import de.schildbach.pte.dto.QueryDeparturesResult;
/**
@ -33,6 +36,7 @@ import de.schildbach.pte.dto.QueryDeparturesResult;
public class IvbProviderLiveTest
{
private final IvbProvider provider = new IvbProvider();
private static final String ALL_PRODUCTS = "IRSUTBFC";
@Test
public void nearbyStations() throws Exception
@ -73,4 +77,14 @@ public class IvbProviderLiveTest
System.out.print(autocomplete.toDebugString() + " ");
System.out.println();
}
@Test
public void shortConnection() throws Exception
{
final QueryConnectionsResult result = provider.queryConnections(new Location(LocationType.STATION, 60466402, null, "Kochstraße"), null,
new Location(LocationType.STATION, 60461679, null, "Messe/Zeughaus"), new Date(), true, ALL_PRODUCTS, WalkSpeed.NORMAL);
System.out.println(result);
final QueryConnectionsResult moreResult = provider.queryMoreConnections(result.context);
System.out.println(moreResult);
}
}

View file

@ -17,14 +17,17 @@
package de.schildbach.pte.live;
import java.util.Date;
import java.util.List;
import org.junit.Test;
import de.schildbach.pte.MariborProvider;
import de.schildbach.pte.NetworkProvider.WalkSpeed;
import de.schildbach.pte.dto.Location;
import de.schildbach.pte.dto.LocationType;
import de.schildbach.pte.dto.NearbyStationsResult;
import de.schildbach.pte.dto.QueryConnectionsResult;
import de.schildbach.pte.dto.QueryDeparturesResult;
/**
@ -33,6 +36,7 @@ import de.schildbach.pte.dto.QueryDeparturesResult;
public class MariborProviderLiveTest
{
private final MariborProvider provider = new MariborProvider();
private static final String ALL_PRODUCTS = "IRSUTBFC";
@Test
public void nearbyStations() throws Exception
@ -73,4 +77,14 @@ public class MariborProviderLiveTest
System.out.print(autocomplete.toDebugString() + " ");
System.out.println();
}
@Test
public void shortConnection() throws Exception
{
final QueryConnectionsResult result = provider.queryConnections(new Location(LocationType.STATION, 63202999, null, "Graz Marburger Straße"),
null, new Location(LocationType.STATION, 63201746, null, "Flughafen Graz Bahnhof"), new Date(), true, ALL_PRODUCTS, WalkSpeed.NORMAL);
System.out.println(result);
final QueryConnectionsResult moreResult = provider.queryMoreConnections(result.context);
System.out.println(moreResult);
}
}

View file

@ -17,14 +17,17 @@
package de.schildbach.pte.live;
import java.util.Date;
import java.util.List;
import org.junit.Test;
import de.schildbach.pte.MetProvider;
import de.schildbach.pte.NetworkProvider.WalkSpeed;
import de.schildbach.pte.dto.Location;
import de.schildbach.pte.dto.LocationType;
import de.schildbach.pte.dto.NearbyStationsResult;
import de.schildbach.pte.dto.QueryConnectionsResult;
import de.schildbach.pte.dto.QueryDeparturesResult;
/**
@ -33,6 +36,7 @@ import de.schildbach.pte.dto.QueryDeparturesResult;
public class MetProviderLiveTest
{
private final MetProvider provider = new MetProvider();
private static final String ALL_PRODUCTS = "IRSUTBFC";
@Test
public void nearbyStations() throws Exception
@ -73,4 +77,14 @@ public class MetProviderLiveTest
System.out.print(autocomplete.toDebugString() + " ");
System.out.println();
}
@Test
public void shortConnection() throws Exception
{
final QueryConnectionsResult result = provider.queryConnections(new Location(LocationType.STATION, 0, null, "Hauptwache"),
null, new Location(LocationType.STATION, 0, null, "Südbahnhof"), new Date(), true, ALL_PRODUCTS, WalkSpeed.NORMAL);
System.out.println(result);
final QueryConnectionsResult moreResult = provider.queryMoreConnections(result.context);
System.out.println(moreResult);
}
}

View file

@ -17,14 +17,17 @@
package de.schildbach.pte.live;
import java.util.Date;
import java.util.List;
import org.junit.Test;
import de.schildbach.pte.MvgProvider;
import de.schildbach.pte.NetworkProvider.WalkSpeed;
import de.schildbach.pte.dto.Location;
import de.schildbach.pte.dto.LocationType;
import de.schildbach.pte.dto.NearbyStationsResult;
import de.schildbach.pte.dto.QueryConnectionsResult;
import de.schildbach.pte.dto.QueryDeparturesResult;
/**
@ -33,6 +36,7 @@ import de.schildbach.pte.dto.QueryDeparturesResult;
public class MvgProviderLiveTest
{
private final MvgProvider provider = new MvgProvider();
private static final String ALL_PRODUCTS = "IRSUTBFC";
@Test
public void nearbyStations() throws Exception
@ -61,7 +65,7 @@ public class MvgProviderLiveTest
@Test
public void autocompleteIncomplete() throws Exception
{
final List<Location> autocompletes = provider.autocompleteStations("Kurf");
final List<Location> autocompletes = provider.autocompleteStations("Schützenhalle");
list(autocompletes);
}
@ -73,4 +77,14 @@ public class MvgProviderLiveTest
System.out.print(autocomplete.toDebugString() + " ");
System.out.println();
}
@Test
public void shortConnection() throws Exception
{
final QueryConnectionsResult result = provider.queryConnections(new Location(LocationType.STATION, 24510104, null, "Schützenplatz"), null,
new Location(LocationType.STATION, 24064226, null, "Schützenhalle"), new Date(), true, ALL_PRODUCTS, WalkSpeed.NORMAL);
System.out.println(result);
final QueryConnectionsResult moreResult = provider.queryMoreConnections(result.context);
System.out.println(moreResult);
}
}

View file

@ -17,14 +17,17 @@
package de.schildbach.pte.live;
import java.util.Date;
import java.util.List;
import org.junit.Test;
import de.schildbach.pte.NaldoProvider;
import de.schildbach.pte.NetworkProvider.WalkSpeed;
import de.schildbach.pte.dto.Location;
import de.schildbach.pte.dto.LocationType;
import de.schildbach.pte.dto.NearbyStationsResult;
import de.schildbach.pte.dto.QueryConnectionsResult;
import de.schildbach.pte.dto.QueryDeparturesResult;
/**
@ -33,6 +36,7 @@ import de.schildbach.pte.dto.QueryDeparturesResult;
public class NaldoProviderLiveTest
{
private final NaldoProvider provider = new NaldoProvider();
private static final String ALL_PRODUCTS = "IRSUTBFC";
@Test
public void nearbyStations() throws Exception
@ -73,4 +77,14 @@ public class NaldoProviderLiveTest
System.out.print(autocomplete.toDebugString() + " ");
System.out.println();
}
@Test
public void shortConnection() throws Exception
{
final QueryConnectionsResult result = provider.queryConnections(new Location(LocationType.STATION, 3019697, null, "Amberg Kurfürstenbad"),
null, new Location(LocationType.STATION, 3019500, null, "Amberg Bahnhof"), new Date(), true, ALL_PRODUCTS, WalkSpeed.NORMAL);
System.out.println(result);
final QueryConnectionsResult moreResult = provider.queryMoreConnections(result.context);
System.out.println(moreResult);
}
}

View file

@ -17,14 +17,17 @@
package de.schildbach.pte.live;
import java.util.Date;
import java.util.List;
import org.junit.Test;
import de.schildbach.pte.NetworkProvider.WalkSpeed;
import de.schildbach.pte.NvbwProvider;
import de.schildbach.pte.dto.Location;
import de.schildbach.pte.dto.LocationType;
import de.schildbach.pte.dto.NearbyStationsResult;
import de.schildbach.pte.dto.QueryConnectionsResult;
import de.schildbach.pte.dto.QueryDeparturesResult;
/**
@ -33,6 +36,7 @@ import de.schildbach.pte.dto.QueryDeparturesResult;
public class NvbwProviderLiveTest
{
private final NvbwProvider provider = new NvbwProvider();
private static final String ALL_PRODUCTS = "IRSUTBFC";
@Test
public void nearbyStations() throws Exception
@ -73,4 +77,14 @@ public class NvbwProviderLiveTest
System.out.print(autocomplete.toDebugString() + " ");
System.out.println();
}
@Test
public void shortConnection() throws Exception
{
final QueryConnectionsResult result = provider.queryConnections(new Location(LocationType.STATION, 17002402, null, "Bahnhof"), null,
new Location(LocationType.STATION, 17009001, null, "Bahnhof"), new Date(), true, ALL_PRODUCTS, WalkSpeed.NORMAL);
System.out.println(result);
final QueryConnectionsResult moreResult = provider.queryMoreConnections(result.context);
System.out.println(moreResult);
}
}

View file

@ -81,8 +81,8 @@ public class RmvProviderLiveTest
@Test
public void shortConnection() throws Exception
{
final QueryConnectionsResult result = provider.queryConnections(new Location(LocationType.STATION, 8000150, null, "Hanau Hauptbahnhof"),
null, new Location(LocationType.STATION, 8000105, null, "Frankfurt Hauptbahnhof"), new Date(), true, ALL_PRODUCTS, WalkSpeed.NORMAL);
final QueryConnectionsResult result = provider.queryConnections(new Location(LocationType.STATION, 3000001, null, "Hauptwache"),
null, new Location(LocationType.STATION, 3000912, null, "Südbahnhof"), new Date(), true, ALL_PRODUCTS, WalkSpeed.NORMAL);
System.out.println(result);
final QueryConnectionsResult moreResult = provider.queryMoreConnections(result.context);
System.out.println(moreResult);

View file

@ -17,14 +17,17 @@
package de.schildbach.pte.live;
import java.util.Date;
import java.util.List;
import org.junit.Test;
import de.schildbach.pte.SfProvider;
import de.schildbach.pte.NetworkProvider.WalkSpeed;
import de.schildbach.pte.dto.Location;
import de.schildbach.pte.dto.LocationType;
import de.schildbach.pte.dto.NearbyStationsResult;
import de.schildbach.pte.dto.QueryConnectionsResult;
import de.schildbach.pte.dto.QueryDeparturesResult;
/**
@ -33,6 +36,7 @@ import de.schildbach.pte.dto.QueryDeparturesResult;
public class SfProviderLiveTest
{
private final SfProvider provider = new SfProvider();
private static final String ALL_PRODUCTS = "IRSUTBFC";
@Test
public void nearbyStations() throws Exception
@ -73,4 +77,14 @@ public class SfProviderLiveTest
System.out.print(autocomplete.toDebugString() + " ");
System.out.println();
}
@Test
public void shortConnection() throws Exception
{
final QueryConnectionsResult result = provider.queryConnections(new Location(LocationType.STATION, 0, null, "Hauptwache"), null,
new Location(LocationType.STATION, 0, null, "Südbahnhof"), new Date(), true, ALL_PRODUCTS, WalkSpeed.NORMAL);
System.out.println(result);
final QueryConnectionsResult moreResult = provider.queryMoreConnections(result.context);
System.out.println(moreResult);
}
}

View file

@ -17,14 +17,17 @@
package de.schildbach.pte.live;
import java.util.Date;
import java.util.List;
import org.junit.Test;
import de.schildbach.pte.StvProvider;
import de.schildbach.pte.NetworkProvider.WalkSpeed;
import de.schildbach.pte.dto.Location;
import de.schildbach.pte.dto.LocationType;
import de.schildbach.pte.dto.NearbyStationsResult;
import de.schildbach.pte.dto.QueryConnectionsResult;
import de.schildbach.pte.dto.QueryDeparturesResult;
/**
@ -33,6 +36,7 @@ import de.schildbach.pte.dto.QueryDeparturesResult;
public class StvProviderLiveTest
{
private final StvProvider provider = new StvProvider();
private static final String ALL_PRODUCTS = "IRSUTBFC";
@Test
public void nearbyStations() throws Exception
@ -73,4 +77,14 @@ public class StvProviderLiveTest
System.out.print(autocomplete.toDebugString() + " ");
System.out.println();
}
@Test
public void shortConnection() throws Exception
{
final QueryConnectionsResult result = provider.queryConnections(new Location(LocationType.STATION, 0, null, "Hauptwache"),
null, new Location(LocationType.STATION, 0, null, "Südbahnhof"), new Date(), true, ALL_PRODUCTS, WalkSpeed.NORMAL);
System.out.println(result);
final QueryConnectionsResult moreResult = provider.queryMoreConnections(result.context);
System.out.println(moreResult);
}
}

View file

@ -17,14 +17,17 @@
package de.schildbach.pte.live;
import java.util.Date;
import java.util.List;
import org.junit.Test;
import de.schildbach.pte.SvvProvider;
import de.schildbach.pte.NetworkProvider.WalkSpeed;
import de.schildbach.pte.dto.Location;
import de.schildbach.pte.dto.LocationType;
import de.schildbach.pte.dto.NearbyStationsResult;
import de.schildbach.pte.dto.QueryConnectionsResult;
import de.schildbach.pte.dto.QueryDeparturesResult;
/**
@ -33,6 +36,7 @@ import de.schildbach.pte.dto.QueryDeparturesResult;
public class SvvProviderLiveTest
{
private final SvvProvider provider = new SvvProvider();
private static final String ALL_PRODUCTS = "IRSUTBFC";
@Test
public void nearbyStations() throws Exception
@ -73,4 +77,14 @@ public class SvvProviderLiveTest
System.out.print(autocomplete.toDebugString() + " ");
System.out.println();
}
@Test
public void shortConnection() throws Exception
{
final QueryConnectionsResult result = provider.queryConnections(new Location(LocationType.STATION, 0, null, "Hauptwache"), null,
new Location(LocationType.STATION, 0, null, "Südbahnhof"), new Date(), true, ALL_PRODUCTS, WalkSpeed.NORMAL);
System.out.println(result);
final QueryConnectionsResult moreResult = provider.queryMoreConnections(result.context);
System.out.println(moreResult);
}
}

View file

@ -17,14 +17,17 @@
package de.schildbach.pte.live;
import java.util.Date;
import java.util.List;
import org.junit.Test;
import de.schildbach.pte.SydneyProvider;
import de.schildbach.pte.NetworkProvider.WalkSpeed;
import de.schildbach.pte.dto.Location;
import de.schildbach.pte.dto.LocationType;
import de.schildbach.pte.dto.NearbyStationsResult;
import de.schildbach.pte.dto.QueryConnectionsResult;
import de.schildbach.pte.dto.QueryDeparturesResult;
/**
@ -33,6 +36,7 @@ import de.schildbach.pte.dto.QueryDeparturesResult;
public class SydneyProviderLiveTest
{
private final SydneyProvider provider = new SydneyProvider();
private static final String ALL_PRODUCTS = "IRSUTBFC";
@Test
public void nearbyStations() throws Exception
@ -73,4 +77,14 @@ public class SydneyProviderLiveTest
System.out.print(autocomplete.toDebugString() + " ");
System.out.println();
}
@Test
public void shortConnection() throws Exception
{
final QueryConnectionsResult result = provider.queryConnections(new Location(LocationType.STATION, 0, null, "Hauptwache"), null,
new Location(LocationType.STATION, 0, null, "Südbahnhof"), new Date(), true, ALL_PRODUCTS, WalkSpeed.NORMAL);
System.out.println(result);
final QueryConnectionsResult moreResult = provider.queryMoreConnections(result.context);
System.out.println(moreResult);
}
}

View file

@ -78,6 +78,16 @@ public class TflProviderLiveTest
System.out.println();
}
@Test
public void shortConnection() throws Exception
{
final QueryConnectionsResult result = provider.queryConnections(new Location(LocationType.STATION, 1008730, null, "King & Queen Wharf"), null,
new Location(LocationType.STATION, 1006433, null, "Edinburgh Court"), new Date(), true, ALL_PRODUCTS, WalkSpeed.NORMAL);
System.out.println(result);
final QueryConnectionsResult moreResult = provider.queryMoreConnections(result.context);
System.out.println(moreResult);
}
@Test
public void postcodeConnection() throws Exception
{

View file

@ -17,14 +17,17 @@
package de.schildbach.pte.live;
import java.util.Date;
import java.util.List;
import org.junit.Test;
import de.schildbach.pte.TleaProvider;
import de.schildbach.pte.NetworkProvider.WalkSpeed;
import de.schildbach.pte.dto.Location;
import de.schildbach.pte.dto.LocationType;
import de.schildbach.pte.dto.NearbyStationsResult;
import de.schildbach.pte.dto.QueryConnectionsResult;
import de.schildbach.pte.dto.QueryDeparturesResult;
/**
@ -33,6 +36,7 @@ import de.schildbach.pte.dto.QueryDeparturesResult;
public class TleaProviderLiveTest
{
private final TleaProvider provider = new TleaProvider();
private static final String ALL_PRODUCTS = "IRSUTBFC";
@Test
public void nearbyStations() throws Exception
@ -73,4 +77,14 @@ public class TleaProviderLiveTest
System.out.print(autocomplete.toDebugString() + " ");
System.out.println();
}
@Test
public void shortConnection() throws Exception
{
final QueryConnectionsResult result = provider.queryConnections(new Location(LocationType.STATION, 1008730, null, "King & Queen Wharf"),
null, new Location(LocationType.STATION, 1006433, null, "Edinburgh Court"), new Date(), true, ALL_PRODUCTS, WalkSpeed.NORMAL);
System.out.println(result);
final QueryConnectionsResult moreResult = provider.queryMoreConnections(result.context);
System.out.println(moreResult);
}
}

View file

@ -17,14 +17,17 @@
package de.schildbach.pte.live;
import java.util.Date;
import java.util.List;
import org.junit.Test;
import de.schildbach.pte.TlemProvider;
import de.schildbach.pte.NetworkProvider.WalkSpeed;
import de.schildbach.pte.dto.Location;
import de.schildbach.pte.dto.LocationType;
import de.schildbach.pte.dto.NearbyStationsResult;
import de.schildbach.pte.dto.QueryConnectionsResult;
import de.schildbach.pte.dto.QueryDeparturesResult;
/**
@ -33,6 +36,7 @@ import de.schildbach.pte.dto.QueryDeparturesResult;
public class TlemProviderLiveTest
{
private final TlemProvider provider = new TlemProvider();
private static final String ALL_PRODUCTS = "IRSUTBFC";
@Test
public void nearbyStations() throws Exception
@ -73,4 +77,14 @@ public class TlemProviderLiveTest
System.out.print(autocomplete.toDebugString() + " ");
System.out.println();
}
@Test
public void shortConnection() throws Exception
{
final QueryConnectionsResult result = provider.queryConnections(new Location(LocationType.STATION, 1008730, null, "King & Queen Wharf"),
null, new Location(LocationType.STATION, 1006433, null, "Edinburgh Court"), new Date(), true, ALL_PRODUCTS, WalkSpeed.NORMAL);
System.out.println(result);
final QueryConnectionsResult moreResult = provider.queryMoreConnections(result.context);
System.out.println(moreResult);
}
}

View file

@ -17,14 +17,17 @@
package de.schildbach.pte.live;
import java.util.Date;
import java.util.List;
import org.junit.Test;
import de.schildbach.pte.TlseProvider;
import de.schildbach.pte.NetworkProvider.WalkSpeed;
import de.schildbach.pte.dto.Location;
import de.schildbach.pte.dto.LocationType;
import de.schildbach.pte.dto.NearbyStationsResult;
import de.schildbach.pte.dto.QueryConnectionsResult;
import de.schildbach.pte.dto.QueryDeparturesResult;
/**
@ -33,6 +36,7 @@ import de.schildbach.pte.dto.QueryDeparturesResult;
public class TlseProviderLiveTest
{
private final TlseProvider provider = new TlseProvider();
private static final String ALL_PRODUCTS = "IRSUTBFC";
@Test
public void nearbyStations() throws Exception
@ -73,4 +77,14 @@ public class TlseProviderLiveTest
System.out.print(autocomplete.toDebugString() + " ");
System.out.println();
}
@Test
public void shortConnection() throws Exception
{
final QueryConnectionsResult result = provider.queryConnections(new Location(LocationType.STATION, 1008730, null, "King & Queen Wharf"),
null, new Location(LocationType.STATION, 1006433, null, "Edinburgh Court"), new Date(), true, ALL_PRODUCTS, WalkSpeed.NORMAL);
System.out.println(result);
final QueryConnectionsResult moreResult = provider.queryMoreConnections(result.context);
System.out.println(moreResult);
}
}

View file

@ -17,14 +17,17 @@
package de.schildbach.pte.live;
import java.util.Date;
import java.util.List;
import org.junit.Test;
import de.schildbach.pte.TlswProvider;
import de.schildbach.pte.NetworkProvider.WalkSpeed;
import de.schildbach.pte.dto.Location;
import de.schildbach.pte.dto.LocationType;
import de.schildbach.pte.dto.NearbyStationsResult;
import de.schildbach.pte.dto.QueryConnectionsResult;
import de.schildbach.pte.dto.QueryDeparturesResult;
/**
@ -33,6 +36,7 @@ import de.schildbach.pte.dto.QueryDeparturesResult;
public class TlswProviderLiveTest
{
private final TlswProvider provider = new TlswProvider();
private static final String ALL_PRODUCTS = "IRSUTBFC";
@Test
public void nearbyStations() throws Exception
@ -73,4 +77,14 @@ public class TlswProviderLiveTest
System.out.print(autocomplete.toDebugString() + " ");
System.out.println();
}
@Test
public void shortConnection() throws Exception
{
final QueryConnectionsResult result = provider.queryConnections(new Location(LocationType.STATION, 0, null, "Hauptwache"), null,
new Location(LocationType.STATION, 0, null, "Südbahnhof"), new Date(), true, ALL_PRODUCTS, WalkSpeed.NORMAL);
System.out.println(result);
final QueryConnectionsResult moreResult = provider.queryMoreConnections(result.context);
System.out.println(moreResult);
}
}

View file

@ -17,14 +17,17 @@
package de.schildbach.pte.live;
import java.util.Date;
import java.util.List;
import org.junit.Test;
import de.schildbach.pte.VagfrProvider;
import de.schildbach.pte.NetworkProvider.WalkSpeed;
import de.schildbach.pte.dto.Location;
import de.schildbach.pte.dto.LocationType;
import de.schildbach.pte.dto.NearbyStationsResult;
import de.schildbach.pte.dto.QueryConnectionsResult;
import de.schildbach.pte.dto.QueryDeparturesResult;
/**
@ -33,6 +36,7 @@ import de.schildbach.pte.dto.QueryDeparturesResult;
public class VagfrProviderLiveTest
{
private final VagfrProvider provider = new VagfrProvider();
private static final String ALL_PRODUCTS = "IRSUTBFC";
@Test
public void nearbyStations() throws Exception
@ -73,4 +77,14 @@ public class VagfrProviderLiveTest
System.out.print(autocomplete.toDebugString() + " ");
System.out.println();
}
@Test
public void shortConnection() throws Exception
{
final QueryConnectionsResult result = provider.queryConnections(new Location(LocationType.STATION, 0, null, "Hauptwache"), null,
new Location(LocationType.STATION, 0, null, "Südbahnhof"), new Date(), true, ALL_PRODUCTS, WalkSpeed.NORMAL);
System.out.println(result);
final QueryConnectionsResult moreResult = provider.queryMoreConnections(result.context);
System.out.println(moreResult);
}
}

View file

@ -17,14 +17,17 @@
package de.schildbach.pte.live;
import java.util.Date;
import java.util.List;
import org.junit.Test;
import de.schildbach.pte.VblProvider;
import de.schildbach.pte.NetworkProvider.WalkSpeed;
import de.schildbach.pte.dto.Location;
import de.schildbach.pte.dto.LocationType;
import de.schildbach.pte.dto.NearbyStationsResult;
import de.schildbach.pte.dto.QueryConnectionsResult;
import de.schildbach.pte.dto.QueryDeparturesResult;
/**
@ -33,6 +36,7 @@ import de.schildbach.pte.dto.QueryDeparturesResult;
public class VblProviderLiveTest
{
private final VblProvider provider = new VblProvider();
private static final String ALL_PRODUCTS = "IRSUTBFC";
@Test
public void nearbyStations() throws Exception
@ -73,4 +77,14 @@ public class VblProviderLiveTest
System.out.print(autocomplete.toDebugString() + " ");
System.out.println();
}
@Test
public void shortConnection() throws Exception
{
final QueryConnectionsResult result = provider.queryConnections(new Location(LocationType.STATION, 0, null, "Hauptwache"), null,
new Location(LocationType.STATION, 0, null, "Südbahnhof"), new Date(), true, ALL_PRODUCTS, WalkSpeed.NORMAL);
System.out.println(result);
final QueryConnectionsResult moreResult = provider.queryMoreConnections(result.context);
System.out.println(moreResult);
}
}

View file

@ -17,14 +17,17 @@
package de.schildbach.pte.live;
import java.util.Date;
import java.util.List;
import org.junit.Test;
import de.schildbach.pte.VgsProvider;
import de.schildbach.pte.NetworkProvider.WalkSpeed;
import de.schildbach.pte.dto.Location;
import de.schildbach.pte.dto.LocationType;
import de.schildbach.pte.dto.NearbyStationsResult;
import de.schildbach.pte.dto.QueryConnectionsResult;
import de.schildbach.pte.dto.QueryDeparturesResult;
/**
@ -33,6 +36,7 @@ import de.schildbach.pte.dto.QueryDeparturesResult;
public class VgsProviderLiveTest
{
private final VgsProvider provider = new VgsProvider();
private static final String ALL_PRODUCTS = "IRSUTBFC";
@Test
public void nearbyStations() throws Exception
@ -73,4 +77,14 @@ public class VgsProviderLiveTest
System.out.println(result.stationDepartures);
}
@Test
public void shortConnection() throws Exception
{
final QueryConnectionsResult result = provider.queryConnections(new Location(LocationType.STATION, 0, null, "Hauptwache"), null,
new Location(LocationType.STATION, 0, null, "Südbahnhof"), new Date(), true, ALL_PRODUCTS, WalkSpeed.NORMAL);
System.out.println(result);
final QueryConnectionsResult moreResult = provider.queryMoreConnections(result.context);
System.out.println(moreResult);
}
}

View file

@ -17,14 +17,17 @@
package de.schildbach.pte.live;
import java.util.Date;
import java.util.List;
import org.junit.Test;
import de.schildbach.pte.NetworkProvider.WalkSpeed;
import de.schildbach.pte.VmobilProvider;
import de.schildbach.pte.dto.Location;
import de.schildbach.pte.dto.LocationType;
import de.schildbach.pte.dto.NearbyStationsResult;
import de.schildbach.pte.dto.QueryConnectionsResult;
import de.schildbach.pte.dto.QueryDeparturesResult;
/**
@ -33,6 +36,7 @@ import de.schildbach.pte.dto.QueryDeparturesResult;
public class VmobilProviderLiveTest
{
private final VmobilProvider provider = new VmobilProvider();
private static final String ALL_PRODUCTS = "IRSUTBFC";
@Test
public void nearbyStations() throws Exception
@ -73,4 +77,14 @@ public class VmobilProviderLiveTest
System.out.print(autocomplete.toDebugString() + " ");
System.out.println();
}
@Test
public void shortConnection() throws Exception
{
final QueryConnectionsResult result = provider.queryConnections(new Location(LocationType.STATION, 0, null, "Hauptwache"), null,
new Location(LocationType.STATION, 0, null, "Südbahnhof"), new Date(), true, ALL_PRODUCTS, WalkSpeed.NORMAL);
System.out.println(result);
final QueryConnectionsResult moreResult = provider.queryMoreConnections(result.context);
System.out.println(moreResult);
}
}

View file

@ -17,14 +17,17 @@
package de.schildbach.pte.live;
import java.util.Date;
import java.util.List;
import org.junit.Test;
import de.schildbach.pte.VmsProvider;
import de.schildbach.pte.NetworkProvider.WalkSpeed;
import de.schildbach.pte.dto.Location;
import de.schildbach.pte.dto.LocationType;
import de.schildbach.pte.dto.NearbyStationsResult;
import de.schildbach.pte.dto.QueryConnectionsResult;
import de.schildbach.pte.dto.QueryDeparturesResult;
/**
@ -33,6 +36,7 @@ import de.schildbach.pte.dto.QueryDeparturesResult;
public class VmsProviderLiveTest
{
private final VmsProvider provider = new VmsProvider();
private static final String ALL_PRODUCTS = "IRSUTBFC";
@Test
public void nearbyStations() throws Exception
@ -73,4 +77,14 @@ public class VmsProviderLiveTest
System.out.print(autocomplete.toDebugString() + " ");
System.out.println();
}
@Test
public void shortConnection() throws Exception
{
final QueryConnectionsResult result = provider.queryConnections(new Location(LocationType.STATION, 0, null, "Hauptwache"), null,
new Location(LocationType.STATION, 0, null, "Südbahnhof"), new Date(), true, ALL_PRODUCTS, WalkSpeed.NORMAL);
System.out.println(result);
final QueryConnectionsResult moreResult = provider.queryMoreConnections(result.context);
System.out.println(moreResult);
}
}

View file

@ -17,14 +17,17 @@
package de.schildbach.pte.live;
import java.util.Date;
import java.util.List;
import org.junit.Test;
import de.schildbach.pte.VmvProvider;
import de.schildbach.pte.NetworkProvider.WalkSpeed;
import de.schildbach.pte.dto.Location;
import de.schildbach.pte.dto.LocationType;
import de.schildbach.pte.dto.NearbyStationsResult;
import de.schildbach.pte.dto.QueryConnectionsResult;
import de.schildbach.pte.dto.QueryDeparturesResult;
/**
@ -33,6 +36,7 @@ import de.schildbach.pte.dto.QueryDeparturesResult;
public class VmvProviderLiveTest
{
private final VmvProvider provider = new VmvProvider();
private static final String ALL_PRODUCTS = "IRSUTBFC";
@Test
public void nearbyStations() throws Exception
@ -73,4 +77,14 @@ public class VmvProviderLiveTest
System.out.print(autocomplete.toDebugString() + " ");
System.out.println();
}
@Test
public void shortConnection() throws Exception
{
final QueryConnectionsResult result = provider.queryConnections(new Location(LocationType.STATION, 0, null, "Hauptwache"), null,
new Location(LocationType.STATION, 0, null, "Südbahnhof"), new Date(), true, ALL_PRODUCTS, WalkSpeed.NORMAL);
System.out.println(result);
final QueryConnectionsResult moreResult = provider.queryMoreConnections(result.context);
System.out.println(moreResult);
}
}

View file

@ -17,14 +17,17 @@
package de.schildbach.pte.live;
import java.util.Date;
import java.util.List;
import org.junit.Test;
import de.schildbach.pte.VorProvider;
import de.schildbach.pte.NetworkProvider.WalkSpeed;
import de.schildbach.pte.dto.Location;
import de.schildbach.pte.dto.LocationType;
import de.schildbach.pte.dto.NearbyStationsResult;
import de.schildbach.pte.dto.QueryConnectionsResult;
import de.schildbach.pte.dto.QueryDeparturesResult;
/**
@ -33,6 +36,7 @@ import de.schildbach.pte.dto.QueryDeparturesResult;
public class VorProviderLiveTest
{
private final VorProvider provider = new VorProvider();
private static final String ALL_PRODUCTS = "IRSUTBFC";
@Test
public void nearbyStations() throws Exception
@ -73,4 +77,14 @@ public class VorProviderLiveTest
System.out.print(autocomplete.toDebugString() + " ");
System.out.println();
}
@Test
public void shortConnection() throws Exception
{
final QueryConnectionsResult result = provider.queryConnections(new Location(LocationType.STATION, 0, null, "Hauptwache"), null,
new Location(LocationType.STATION, 0, null, "Südbahnhof"), new Date(), true, ALL_PRODUCTS, WalkSpeed.NORMAL);
System.out.println(result);
final QueryConnectionsResult moreResult = provider.queryMoreConnections(result.context);
System.out.println(moreResult);
}
}

View file

@ -17,14 +17,17 @@
package de.schildbach.pte.live;
import java.util.Date;
import java.util.List;
import org.junit.Test;
import de.schildbach.pte.VrnProvider;
import de.schildbach.pte.NetworkProvider.WalkSpeed;
import de.schildbach.pte.dto.Location;
import de.schildbach.pte.dto.LocationType;
import de.schildbach.pte.dto.NearbyStationsResult;
import de.schildbach.pte.dto.QueryConnectionsResult;
import de.schildbach.pte.dto.QueryDeparturesResult;
/**
@ -33,6 +36,7 @@ import de.schildbach.pte.dto.QueryDeparturesResult;
public class VrnProviderLiveTest
{
private final VrnProvider provider = new VrnProvider();
private static final String ALL_PRODUCTS = "IRSUTBFC";
@Test
public void nearbyStations() throws Exception
@ -97,4 +101,14 @@ public class VrnProviderLiveTest
System.out.print(autocomplete.toDebugString() + " ");
System.out.println();
}
@Test
public void shortConnection() throws Exception
{
final QueryConnectionsResult result = provider.queryConnections(new Location(LocationType.STATION, 0, null, "Hauptwache"), null,
new Location(LocationType.STATION, 0, null, "Südbahnhof"), new Date(), true, ALL_PRODUCTS, WalkSpeed.NORMAL);
System.out.println(result);
final QueryConnectionsResult moreResult = provider.queryMoreConnections(result.context);
System.out.println(moreResult);
}
}

View file

@ -17,14 +17,17 @@
package de.schildbach.pte.live;
import java.util.Date;
import java.util.List;
import org.junit.Test;
import de.schildbach.pte.VrrProvider;
import de.schildbach.pte.NetworkProvider.WalkSpeed;
import de.schildbach.pte.dto.Location;
import de.schildbach.pte.dto.LocationType;
import de.schildbach.pte.dto.NearbyStationsResult;
import de.schildbach.pte.dto.QueryConnectionsResult;
import de.schildbach.pte.dto.QueryDeparturesResult;
/**
@ -33,6 +36,7 @@ import de.schildbach.pte.dto.QueryDeparturesResult;
public class VrrProviderLiveTest
{
private final VrrProvider provider = new VrrProvider();
private static final String ALL_PRODUCTS = "IRSUTBFC";
@Test
public void nearbyStations() throws Exception
@ -89,4 +93,14 @@ public class VrrProviderLiveTest
System.out.print(autocomplete.toDebugString() + " ");
System.out.println();
}
@Test
public void shortConnection() throws Exception
{
final QueryConnectionsResult result = provider.queryConnections(new Location(LocationType.STATION, 0, null, "Hauptwache"), null,
new Location(LocationType.STATION, 0, null, "Südbahnhof"), new Date(), true, ALL_PRODUCTS, WalkSpeed.NORMAL);
System.out.println(result);
final QueryConnectionsResult moreResult = provider.queryMoreConnections(result.context);
System.out.println(moreResult);
}
}

View file

@ -17,14 +17,17 @@
package de.schildbach.pte.live;
import java.util.Date;
import java.util.List;
import org.junit.Test;
import de.schildbach.pte.VrtProvider;
import de.schildbach.pte.NetworkProvider.WalkSpeed;
import de.schildbach.pte.dto.Location;
import de.schildbach.pte.dto.LocationType;
import de.schildbach.pte.dto.NearbyStationsResult;
import de.schildbach.pte.dto.QueryConnectionsResult;
import de.schildbach.pte.dto.QueryDeparturesResult;
/**
@ -33,6 +36,7 @@ import de.schildbach.pte.dto.QueryDeparturesResult;
public class VrtProviderLiveTest
{
private final VrtProvider provider = new VrtProvider();
private static final String ALL_PRODUCTS = "IRSUTBFC";
@Test
public void nearbyStations() throws Exception
@ -73,4 +77,14 @@ public class VrtProviderLiveTest
System.out.print(autocomplete.toDebugString() + " ");
System.out.println();
}
@Test
public void shortConnection() throws Exception
{
final QueryConnectionsResult result = provider.queryConnections(new Location(LocationType.STATION, 17002402, null, "Bahnhof"), null,
new Location(LocationType.STATION, 17009001, null, "Bahnhof"), new Date(), true, ALL_PRODUCTS, WalkSpeed.NORMAL);
System.out.println(result);
final QueryConnectionsResult moreResult = provider.queryMoreConnections(result.context);
System.out.println(moreResult);
}
}

View file

@ -17,14 +17,17 @@
package de.schildbach.pte.live;
import java.util.Date;
import java.util.List;
import org.junit.Test;
import de.schildbach.pte.VvmProvider;
import de.schildbach.pte.NetworkProvider.WalkSpeed;
import de.schildbach.pte.dto.Location;
import de.schildbach.pte.dto.LocationType;
import de.schildbach.pte.dto.NearbyStationsResult;
import de.schildbach.pte.dto.QueryConnectionsResult;
import de.schildbach.pte.dto.QueryDeparturesResult;
/**
@ -33,6 +36,7 @@ import de.schildbach.pte.dto.QueryDeparturesResult;
public class VvmProviderLiveTest
{
private final VvmProvider provider = new VvmProvider();
private static final String ALL_PRODUCTS = "IRSUTBFC";
@Test
public void nearbyStations() throws Exception
@ -73,4 +77,14 @@ public class VvmProviderLiveTest
System.out.print(autocomplete.toDebugString() + " ");
System.out.println();
}
@Test
public void shortConnection() throws Exception
{
final QueryConnectionsResult result = provider.queryConnections(new Location(LocationType.STATION, 0, null, "Hauptwache"), null,
new Location(LocationType.STATION, 0, null, "Südbahnhof"), new Date(), true, ALL_PRODUCTS, WalkSpeed.NORMAL);
System.out.println(result);
final QueryConnectionsResult moreResult = provider.queryMoreConnections(result.context);
System.out.println(moreResult);
}
}

View file

@ -17,14 +17,17 @@
package de.schildbach.pte.live;
import java.util.Date;
import java.util.List;
import org.junit.Test;
import de.schildbach.pte.VvoProvider;
import de.schildbach.pte.NetworkProvider.WalkSpeed;
import de.schildbach.pte.dto.Location;
import de.schildbach.pte.dto.LocationType;
import de.schildbach.pte.dto.NearbyStationsResult;
import de.schildbach.pte.dto.QueryConnectionsResult;
import de.schildbach.pte.dto.QueryDeparturesResult;
/**
@ -33,6 +36,7 @@ import de.schildbach.pte.dto.QueryDeparturesResult;
public class VvoProviderLiveTest
{
private final VvoProvider provider = new VvoProvider();
private static final String ALL_PRODUCTS = "IRSUTBFC";
@Test
public void nearbyStations() throws Exception
@ -73,4 +77,14 @@ public class VvoProviderLiveTest
System.out.print(autocomplete.toDebugString() + " ");
System.out.println();
}
@Test
public void shortConnection() throws Exception
{
final QueryConnectionsResult result = provider.queryConnections(new Location(LocationType.STATION, 0, null, "Hauptwache"), null,
new Location(LocationType.STATION, 0, null, "Südbahnhof"), new Date(), true, ALL_PRODUCTS, WalkSpeed.NORMAL);
System.out.println(result);
final QueryConnectionsResult moreResult = provider.queryMoreConnections(result.context);
System.out.println(moreResult);
}
}

View file

@ -17,14 +17,17 @@
package de.schildbach.pte.live;
import java.util.Date;
import java.util.List;
import org.junit.Test;
import de.schildbach.pte.VvsProvider;
import de.schildbach.pte.NetworkProvider.WalkSpeed;
import de.schildbach.pte.dto.Location;
import de.schildbach.pte.dto.LocationType;
import de.schildbach.pte.dto.NearbyStationsResult;
import de.schildbach.pte.dto.QueryConnectionsResult;
import de.schildbach.pte.dto.QueryDeparturesResult;
/**
@ -33,6 +36,7 @@ import de.schildbach.pte.dto.QueryDeparturesResult;
public class VvsProviderLiveTest
{
private final VvsProvider provider = new VvsProvider();
private static final String ALL_PRODUCTS = "IRSUTBFC";
@Test
public void nearbyStations() throws Exception
@ -73,4 +77,14 @@ public class VvsProviderLiveTest
System.out.print(autocomplete.toDebugString() + " ");
System.out.println();
}
@Test
public void shortConnection() throws Exception
{
final QueryConnectionsResult result = provider.queryConnections(new Location(LocationType.STATION, 0, null, "Hauptwache"), null,
new Location(LocationType.STATION, 0, null, "Südbahnhof"), new Date(), true, ALL_PRODUCTS, WalkSpeed.NORMAL);
System.out.println(result);
final QueryConnectionsResult moreResult = provider.queryMoreConnections(result.context);
System.out.println(moreResult);
}
}