Skip to content

Commit 02ceafb

Browse files
committed
some final fixes after merging master to turn_costs
1 parent e7b6789 commit 02ceafb

File tree

3 files changed

+8
-13
lines changed

3 files changed

+8
-13
lines changed

core/src/main/java/com/graphhopper/storage/GraphHopperStorage.java

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1365,14 +1365,6 @@ public boolean loadExisting()
13651365
checkInit();
13661366
if (nodes.loadExisting())
13671367
{
1368-
if (!properties.loadExisting())
1369-
throw new IllegalStateException("Cannot load properties. Corrupt file or directory? " + dir);
1370-
1371-
if (!extStorage.loadExisting())
1372-
{
1373-
throw new IllegalStateException("cannot load extended storage. corrupt file or directory? " + dir);
1374-
}
1375-
13761368
String acceptStr = "";
13771369
if (properties.loadExisting())
13781370
{

core/src/test/java/com/graphhopper/GraphHopperTest.java

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -73,7 +73,8 @@ public void testLoadOSM()
7373
assertEquals(3, ph.getPoints().getSize());
7474

7575
closableInstance.close();
76-
closableInstance = new GraphHopper().setStoreOnFlush(true);
76+
closableInstance = new GraphHopper().setStoreOnFlush(true).
77+
setEncodingManager(new EncodingManager("CAR"));
7778
assertTrue(closableInstance.load(ghLoc));
7879
ph = closableInstance.route(new GHRequest(51.2492152, 9.4317166, 51.2, 9.4));
7980
assertTrue(ph.isFound());
@@ -114,7 +115,8 @@ public void testLoadOSMNoCH()
114115

115116
gh.close();
116117
gh = new GraphHopper().setStoreOnFlush(true).
117-
setCHEnable(false);
118+
setCHEnable(false).
119+
setEncodingManager(new EncodingManager("CAR"));
118120
assertTrue(gh.load(ghLoc));
119121
ph = gh.route(new GHRequest(51.2492152, 9.4317166, 51.2, 9.4));
120122
assertTrue(ph.isFound());
@@ -470,6 +472,7 @@ public void testPrepareOnly()
470472

471473
// use the encoding manager from the graph
472474
instance = new GraphHopper().setStoreOnFlush(true).
475+
setEncodingManager(new EncodingManager("FOOT")).
473476
setCHWeighting("shortest").
474477
setGraphHopperLocation(ghLoc).
475478
setOSMFile(testOsm3);

web/nbactions.xml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@
2828
<goal>org.codehaus.mojo:exec-maven-plugin:1.2.1:exec</goal>
2929
</goals>
3030
<properties>
31-
<exec.args>-classpath %classpath com.graphhopper.http.GHServer graph.elevation.cachedir=../srtmprovider jetty.port=8989 config=../config.properties osmreader.osm=../core/files/monaco.osm.gz</exec.args>
31+
<exec.args>-classpath %classpath com.graphhopper.http.GHServer graph.elevation.cachedir=../srtmprovider jetty.port=8989 config=../config.properties osmreader.osm=../core/files/andorra.osm.gz</exec.args>
3232
<exec.executable>java</exec.executable>
3333
</properties>
3434
</action>
@@ -42,7 +42,7 @@
4242
<goal>org.codehaus.mojo:exec-maven-plugin:1.2.1:exec</goal>
4343
</goals>
4444
<properties>
45-
<exec.args>-Xdebug -Xrunjdwp:transport=dt_socket,server=n,address=${jpda.address} -classpath %classpath com.graphhopper.http.GHServer graph.elevation.cachedir=../srtmprovider jetty.port=8989 config=../config.properties osmreader.osm=../core/files/monaco.osm.gz</exec.args>
45+
<exec.args>-Xdebug -Xrunjdwp:transport=dt_socket,server=n,address=${jpda.address} -classpath %classpath com.graphhopper.http.GHServer graph.elevation.cachedir=../srtmprovider jetty.port=8989 config=../config.properties osmreader.osm=../core/files/andorra.osm.gz</exec.args>
4646
<exec.executable>java</exec.executable>
4747
<jpda.listen>true</jpda.listen>
4848
</properties>
@@ -57,7 +57,7 @@
5757
<goal>org.codehaus.mojo:exec-maven-plugin:1.2.1:exec</goal>
5858
</goals>
5959
<properties>
60-
<exec.args>-classpath %classpath com.graphhopper.http.GHServer graph.elevation.cachedir=../srtmprovider jetty.port=8989 config=../config.properties osmreader.osm=../core/files/monaco.osm.gz</exec.args>
60+
<exec.args>-classpath %classpath com.graphhopper.http.GHServer graph.elevation.cachedir=../srtmprovider jetty.port=8989 config=../config.properties osmreader.osm=../core/files/andorra.osm.gz</exec.args>
6161
<exec.executable>java</exec.executable>
6262
</properties>
6363
</action>

0 commit comments

Comments
 (0)