VGN: Add API base.

This commit is contained in:
Andreas Schildbach 2017-02-06 11:05:44 +01:00
parent 4f6da7336a
commit 35adb1c688
3 changed files with 6 additions and 4 deletions

View file

@ -36,9 +36,14 @@ import okhttp3.HttpUrl;
* @author Andreas Schildbach
*/
public class VgnProvider extends AbstractEfaProvider {
private static final HttpUrl API_BASE = HttpUrl.parse("https://efa.vgn.de/vgn/");
private static final String DEPARTURE_MONITOR_ENDPOINT = "XML_DM_REQUEST";
private static final String TRIP_ENDPOINT = "XML_TRIP_REQUEST2";
public VgnProvider() {
this(API_BASE);
}
public VgnProvider(final HttpUrl apiBase) {
super(NetworkId.VGN, apiBase, DEPARTURE_MONITOR_ENDPOINT, TRIP_ENDPOINT, null, null);
}

View file

@ -35,14 +35,12 @@ import de.schildbach.pte.dto.QueryDeparturesResult;
import de.schildbach.pte.dto.QueryTripsResult;
import de.schildbach.pte.dto.SuggestLocationsResult;
import okhttp3.HttpUrl;
/**
* @author Andreas Schildbach
*/
public class VgnProviderLiveTest extends AbstractProviderLiveTest {
public VgnProviderLiveTest() {
super(new VgnProvider(HttpUrl.parse(secretProperty("vgn.api_base"))));
super(new VgnProvider());
}
@Test

View file

@ -1,5 +1,4 @@
# Secrets are needed to run some of the live tests.
vgn.api_base =
navitia.authorization =
bvg.api_authorization =
vbn.api_authorization =