Mercurial > dive4elements > river
comparison gwt-client/src/test/java/test/BerechnungsartenTester.java @ 9148:48d87af1243e
Unit testing flowdepthdevelopment added
author | gernotbelger |
---|---|
date | Tue, 12 Jun 2018 15:04:40 +0200 |
parents | af73fdd96920 |
children | 83aee0942eae |
comparison
equal
deleted
inserted
replaced
9147:28fe5e654495 | 9148:48d87af1243e |
---|---|
26 public static enum CalcMode { | 26 public static enum CalcMode { |
27 sinfo_calc_flow_depth, sinfo_calc_flow_depth_development, sinfo_calc_flow_depth_minmax, sinfo_calc_collision, Transportkörperhöhen, sinfo_calc_flood_duration | 27 sinfo_calc_flow_depth, sinfo_calc_flow_depth_development, sinfo_calc_flow_depth_minmax, sinfo_calc_collision, Transportkörperhöhen, sinfo_calc_flood_duration |
28 }; | 28 }; |
29 | 29 |
30 public static enum River { | 30 public static enum River { |
31 Beispielfluss, Rhein | 31 Beispielfluss, Rhein, Elbe |
32 }; | 32 }; |
33 | 33 |
34 public static enum FilenameMapper { | 34 public static enum FilenameMapper { |
35 | 35 |
36 HELLO_WORLD_FILE("/sinfo/flowdepthminmax/sinfo_flowdepthminmax_export.csv"), // | 36 HELLO_WORLD_FILE("/sinfo/flowdepthminmax/sinfo_flowdepthminmax_export.csv"), // |
37 | 37 |
38 // Schäfer-Tests: | 38 // Schäfer-Tests: |
39 RHEIN_1_FILE("/sinfo/flowdepth/sinfo_ft_01.csv"), // | 39 FT_RHEIN_1_FILE("/sinfo/flowdepth/sinfo_ft_01.csv"), // |
40 RHEIN_3_FILE("/sinfo/flowdepth/sinfo_ft_03.csv"); // | 40 FT_RHEIN_3_FILE("/sinfo/flowdepth/sinfo_ft_03.csv"), // |
41 | |
42 FTE_ELBE_FILE("/sinfo/flowdepthdevelopment/sinfo_fte_01.csv"), // | |
43 FTE_RHEIN_FILE("/sinfo/flowdepthdevelopment/sinfo_fte_02.csv"); | |
41 | 44 |
42 private final String filename; | 45 private final String filename; |
43 | 46 |
44 FilenameMapper(final String filename) { | 47 FilenameMapper(final String filename) { |
45 this.filename = filename; | 48 this.filename = filename; |
52 | 55 |
53 private final Boolean overrideFileExport() { | 56 private final Boolean overrideFileExport() { |
54 return null; | 57 return null; |
55 } | 58 } |
56 | 59 |
60 /* FLOWDEPTH MIN MAX */ | |
57 @Test | 61 @Test |
58 public void testHelloWorld() throws ServerException, IOException { | 62 public void testHelloWorld() throws ServerException, IOException { |
59 | 63 |
60 /* Hello World Test */ | 64 /* Hello World Test */ |
61 RunnerCreatorHelper.createSinfoFlowdepthMinMaxTest(FilenameMapper.HELLO_WORLD_FILE, 10, 100, River.Beispielfluss) | 65 RunnerCreatorHelper.createSinfoFlowdepthMinMaxTest(FilenameMapper.HELLO_WORLD_FILE, 10, 100, River.Beispielfluss) |
62 .runTest(overrideFileExport() != null ? overrideFileExport() : true); | 66 .runTest(overrideFileExport() != null ? overrideFileExport() : true); |
63 } | 67 } |
64 | 68 |
69 /* FLOWDEPTH */ | |
65 @Test | 70 @Test |
66 public void testRhein1() throws ConnectionException, ServerException, IOException { | 71 public void testRhein1FT() throws ConnectionException, ServerException, IOException { |
67 | 72 |
68 RunnerCreatorHelper | 73 RunnerCreatorHelper |
69 .createSinfoFlowdepthTest(FilenameMapper.RHEIN_1_FILE, 350, 380, River.Rhein, false, | 74 .createSinfoFlowdepthTest(FilenameMapper.FT_RHEIN_1_FILE, 350, 380, River.Rhein, false, |
70 new SimpleRecommendation("staticwqkms", "additionals-wstv-0-415", "longitudinal_section"), | 75 new SimpleRecommendation("staticwqkms", "additionals-wstv-0-415", "longitudinal_section"), |
71 new SimpleRecommendation("bedheight", "bedheight-soundings-79-2004-DGM-2004_Epoche_NHN", "longitudinal_section")) | 76 new SimpleRecommendation("bedheight", "bedheight-soundings-79-2004-DGM-2004_Epoche_NHN", "longitudinal_section")) |
72 .runTest(overrideFileExport() != null ? overrideFileExport() : true); | 77 .runTest(overrideFileExport() != null ? overrideFileExport() : true); |
73 | 78 |
74 } | 79 } |
75 | 80 |
76 @Test | 81 @Test |
77 public void testRhein3() throws ConnectionException, ServerException, IOException { | 82 public void testRhein3FT() throws ConnectionException, ServerException, IOException { |
78 RunnerCreatorHelper | 83 RunnerCreatorHelper |
79 .createSinfoFlowdepthTest(FilenameMapper.RHEIN_3_FILE, 655, 675, River.Rhein, true, | 84 .createSinfoFlowdepthTest(FilenameMapper.FT_RHEIN_3_FILE, 655, 675, River.Rhein, true, |
80 new SimpleRecommendation("staticwqkms", "fixations-wstv-0-323", "longitudinal_section"), | 85 new SimpleRecommendation("staticwqkms", "fixations-wstv-0-323", "longitudinal_section"), |
81 new SimpleRecommendation("bedheight", "bedheight-soundings-92-2004-NIEDERRHEIN_QP-2004_Epoche_NHN", "longitudinal_section")) | 86 new SimpleRecommendation("bedheight", "bedheight-soundings-92-2004-NIEDERRHEIN_QP-2004_Epoche_NHN", "longitudinal_section")) |
82 .runTest(overrideFileExport() != null ? overrideFileExport() : true); | 87 .runTest(overrideFileExport() != null ? overrideFileExport() : true); |
83 } | 88 } |
84 | 89 |
90 /* FLOWDEPTH DEVELOPMENT */ | |
91 | |
92 @Test | |
93 public void testElbeFTE() throws ConnectionException, ServerException, IOException { | |
94 RunnerCreatorHelper.createSinfoFlowdepthDevelopmentTest(FilenameMapper.FTE_ELBE_FILE, 210, 230, River.Elbe, | |
95 // current | |
96 new SimpleRecommendation("staticwqkms", "fixations-wstv-0-196", "longitudinal_section", "05.05.2008"), // sicher | |
97 new SimpleRecommendation("bedheight", "bedheight-soundings-66-2008-FP-QP-2008", | |
98 // "bedheight-single-66-2008-MW-FP-QP-2008", | |
99 "longitudinal_section"), | |
100 | |
101 // historical | |
102 new SimpleRecommendation("staticwqkms", "fixations-wstv-0-186", "longitudinal_section", "18.03.1997"), // sicher | |
103 new SimpleRecommendation("bedheight", "bedheight-soundings-70-1995-QP-1995", | |
104 // "bedheight-single-70-1995-MW-QP-1995", | |
105 "longitudinal_section")) | |
106 .runTest(overrideFileExport() != null ? overrideFileExport() : true); | |
107 } | |
108 | |
109 @Test | |
110 public void testRheinFTE() throws ConnectionException, ServerException, IOException { | |
111 RunnerCreatorHelper.createSinfoFlowdepthDevelopmentTest(FilenameMapper.FTE_RHEIN_FILE, 655, 665, River.Rhein, | |
112 // current | |
113 new SimpleRecommendation("staticwqkms", "fixations-wstv-0-372", "longitudinal_section", "23.09.2009-1"), // sicher | |
114 new SimpleRecommendation("bedheight", "bedheight-soundings-80-2008-FP-2008_NHN", | |
115 // "bedheight-single....", | |
116 "longitudinal_section"), | |
117 | |
118 // historical | |
119 new SimpleRecommendation("staticwqkms", "fixations-wstv-0-374", "longitudinal_section", "18.03.1997"), // sicher | |
120 new SimpleRecommendation("bedheight", "bedheight-single-89-1991-MW-NIEDERRHEIN_QP-1991_Epoche_NHN", | |
121 // "bedheight-soundings-89-1991-NIEDERRHEIN_QP-1991_Epoche_NHN", | |
122 "longitudinal_section")) | |
123 .runTest(overrideFileExport() != null ? overrideFileExport() : true); | |
124 } | |
125 | |
85 } | 126 } |