Mercurial > dive4elements > river
comparison gwt-client/src/test/java/test/BerechnungsartenTester.java @ 9418:9fe26f525ae3
sinfo floodduration jUnit test
author | gernotbelger |
---|---|
date | Thu, 16 Aug 2018 18:15:54 +0200 |
parents | 46e3e23cca0b |
children |
comparison
equal
deleted
inserted
replaced
9417:46e3e23cca0b | 9418:9fe26f525ae3 |
---|---|
2 | 2 |
3 import java.io.IOException; | 3 import java.io.IOException; |
4 | 4 |
5 import org.dive4elements.artifacts.httpclient.exceptions.ConnectionException; | 5 import org.dive4elements.artifacts.httpclient.exceptions.ConnectionException; |
6 import org.dive4elements.river.client.shared.exceptions.ServerException; | 6 import org.dive4elements.river.client.shared.exceptions.ServerException; |
7 import org.junit.Ignore; | |
7 import org.junit.Test; | 8 import org.junit.Test; |
9 | |
10 import test.SinfoFloodDurationRiversideChoice.RiversideChoiceKey; | |
8 | 11 |
9 /** | 12 /** |
10 * @author <a href="mailto:ingo.weinzierl@intevation.de">Ingo Weinzierl</a> | 13 * @author <a href="mailto:ingo.weinzierl@intevation.de">Ingo Weinzierl</a> |
11 */ | 14 */ |
12 | 15 |
13 // REMARK: ignored, because maven will auto-test all tests, but this one needs a running river-artifacts | 16 // REMARK: ignored, because maven will auto-test all tests, but this one needs a running river-artifacts |
14 // For running the JUunit test, the annotation @Ignore has to be disabled | 17 // For running the JUunit test, the annotation @Ignore has to be disabled |
15 | 18 @Ignore |
16 public class BerechnungsartenTester { | 19 public class BerechnungsartenTester { |
17 | 20 |
18 public static enum CalcMode { | 21 public static enum CalcMode { |
19 sinfo_calc_flow_depth, sinfo_calc_flow_depth_development, sinfo_calc_flow_depth_minmax, sinfo_calc_collision, sinfo_calc_transport_bodies_heights, sinfo_calc_flood_duration | 22 sinfo_calc_flow_depth, sinfo_calc_flow_depth_development, sinfo_calc_flow_depth_minmax, sinfo_calc_collision, sinfo_calc_transport_bodies_heights, sinfo_calc_flood_duration |
20 }; | 23 }; |
38 TKH_2_RHEIN_FILE("/sinfo/flowdepthtkh/sinfo_tkh_02.csv"), | 41 TKH_2_RHEIN_FILE("/sinfo/flowdepthtkh/sinfo_tkh_02.csv"), |
39 | 42 |
40 TKH_TKH_RHEIN_FILE("/sinfo/tkh/sinfo_tkh_export.csv"), // | 43 TKH_TKH_RHEIN_FILE("/sinfo/tkh/sinfo_tkh_export.csv"), // |
41 | 44 |
42 COLLISION_RHEIN_HELLO_WORLD_FILE("/sinfo/collision/sinfo_collision_export.csv"), // | 45 COLLISION_RHEIN_HELLO_WORLD_FILE("/sinfo/collision/sinfo_collision_export.csv"), // |
43 COLLISION_RHEIN_EPOCH_HELLO_WORLD_FILE("/sinfo/collision/sinfo_collision_epoch_export.csv"); | 46 COLLISION_RHEIN_EPOCH_HELLO_WORLD_FILE("/sinfo/collision/sinfo_collision_epoch_export.csv"), // |
47 | |
48 FLOOD_DURATION_HELLO_WORLD_FILE("/sinfo/floodduration/sinfo_floodduration_export.csv"); | |
44 private final String filename; | 49 private final String filename; |
45 | 50 |
46 FilenameMapper(final String filename) { | 51 FilenameMapper(final String filename) { |
47 this.filename = filename; | 52 this.filename = filename; |
48 } | 53 } |
168 public void testCollisionEpochs() throws ConnectionException, ServerException, IOException { | 173 public void testCollisionEpochs() throws ConnectionException, ServerException, IOException { |
169 RunnerCreatorHelper.createSinfoCollisionEpochsTest(FilenameMapper.COLLISION_RHEIN_EPOCH_HELLO_WORLD_FILE, 336.2, 866.3, River.Rhein, "2006,2008;") | 174 RunnerCreatorHelper.createSinfoCollisionEpochsTest(FilenameMapper.COLLISION_RHEIN_EPOCH_HELLO_WORLD_FILE, 336.2, 866.3, River.Rhein, "2006,2008;") |
170 .runTest(overrideFileExport() != null ? overrideFileExport() : true); | 175 .runTest(overrideFileExport() != null ? overrideFileExport() : true); |
171 } | 176 } |
172 | 177 |
178 @Test | |
179 public void testFloodDuration() throws ConnectionException, ServerException, IOException { | |
180 RunnerCreatorHelper | |
181 .createSinfoFloodDurationTest(FilenameMapper.FLOOD_DURATION_HELLO_WORLD_FILE, 0, 182.4, River.Beispielfluss, new double[] { 2091.011 }, true, | |
182 RiversideChoiceKey.BOTH) | |
183 | |
184 .runTest(overrideFileExport() != null ? overrideFileExport() : true); | |
185 } | |
186 | |
173 } | 187 } |