From 170ce67fcdd34574984f6dab5b228292b9f7bdfd Mon Sep 17 00:00:00 2001 From: Victor Shcherb Date: Wed, 30 Mar 2016 16:03:06 +0200 Subject: [PATCH] Update test --- OsmAnd-java/.classpath | 1 + OsmAnd-java/build.xml | 4 ++-- .../net/osmand/router/RouteResultPreparationTest.java | 8 ++++---- 3 files changed, 7 insertions(+), 6 deletions(-) diff --git a/OsmAnd-java/.classpath b/OsmAnd-java/.classpath index 67ed15d9d9..8082e6bc02 100644 --- a/OsmAnd-java/.classpath +++ b/OsmAnd-java/.classpath @@ -2,6 +2,7 @@ + diff --git a/OsmAnd-java/build.xml b/OsmAnd-java/build.xml index 3c196f0d33..c28af000dc 100644 --- a/OsmAnd-java/build.xml +++ b/OsmAnd-java/build.xml @@ -53,8 +53,8 @@ - - + + diff --git a/OsmAnd-java/test/java/net/osmand/router/RouteResultPreparationTest.java b/OsmAnd-java/test/java/net/osmand/router/RouteResultPreparationTest.java index a7638b5694..c56e213cc0 100644 --- a/OsmAnd-java/test/java/net/osmand/router/RouteResultPreparationTest.java +++ b/OsmAnd-java/test/java/net/osmand/router/RouteResultPreparationTest.java @@ -2,9 +2,11 @@ package net.osmand.router; import com.google.gson.Gson; import com.google.gson.GsonBuilder; + import net.osmand.PlatformUtil; import net.osmand.binary.BinaryMapIndexReader; import net.osmand.data.LatLon; + import org.apache.commons.logging.Log; import org.junit.Assert; import org.junit.BeforeClass; @@ -63,10 +65,8 @@ public class RouteResultPreparationTest { @Parameterized.Parameters(name = "{index}: {0}") public static Collection data() throws IOException { - - String fileName = "test/resources/test_turn_lanes.json"; - - Reader reader = new FileReader(fileName); + String fileName = "/test_turn_lanes.json"; + Reader reader = new InputStreamReader(RouteResultPreparationTest.class.getResourceAsStream(fileName)); Gson gson = new GsonBuilder().setPrettyPrinting().create(); TestEntry[] testEntries = gson.fromJson(reader, TestEntry[].class); ArrayList twoDArray = new ArrayList();