|
| 1 | +package AlgorithmicGroupTheory; |
| 2 | + |
| 3 | +import static org.junit.Assert.*; |
| 4 | + |
| 5 | +import java.io.IOException; |
| 6 | + |
| 7 | +import org.junit.Test; |
| 8 | +import org.openscience.cdk.exception.CDKException; |
| 9 | + |
| 10 | +public class testMORGEN { |
| 11 | + |
| 12 | + /** |
| 13 | + * This is the junit test class for MORGEN. Randomly selected 40 molecular |
| 14 | + * formulas are used. The number of generated structures are checked. The |
| 15 | + * number of isomers are also tested with MOLGEN algorithm. MORGEN generates |
| 16 | + * same number of isomers like MOLGEN. |
| 17 | + */ |
| 18 | + |
| 19 | + @Test |
| 20 | + |
| 21 | + public void test_C3Cl2H4() throws IOException, CDKException, CloneNotSupportedException { |
| 22 | + MORGEN.formula="C3Cl2H4"; |
| 23 | + MORGEN.run(); |
| 24 | + assertEquals(7,MORGEN.count); |
| 25 | + } |
| 26 | + |
| 27 | + @Test |
| 28 | + |
| 29 | + public void test_C2NO2H5() throws IOException, CDKException, CloneNotSupportedException { |
| 30 | + MORGEN.formula="C2NO2H5"; |
| 31 | + MORGEN.run(); |
| 32 | + assertEquals(84,MORGEN.count); |
| 33 | + } |
| 34 | + |
| 35 | + @Test |
| 36 | + |
| 37 | + public void test_C6H6() throws IOException, CDKException, CloneNotSupportedException { |
| 38 | + MORGEN.formula="C6H6"; |
| 39 | + MORGEN.run(); |
| 40 | + assertEquals(217,MORGEN.count); |
| 41 | + } |
| 42 | + |
| 43 | + @Test |
| 44 | + |
| 45 | + public void test_C3O3H4() throws IOException, CDKException, CloneNotSupportedException { |
| 46 | + MORGEN.formula="C3O3H4"; |
| 47 | + MORGEN.run(); |
| 48 | + assertEquals(152,MORGEN.count); |
| 49 | + } |
| 50 | + |
| 51 | + @Test |
| 52 | + |
| 53 | + public void test_Cl2C5H4() throws IOException, CDKException, CloneNotSupportedException { |
| 54 | + MORGEN.formula="Cl2C5H4"; |
| 55 | + MORGEN.run(); |
| 56 | + assertEquals(217,MORGEN.count); |
| 57 | + } |
| 58 | + |
| 59 | + @Test |
| 60 | + |
| 61 | + public void test_C5H9ClO() throws IOException, CDKException, CloneNotSupportedException { |
| 62 | + MORGEN.formula="C5H9ClO"; |
| 63 | + MORGEN.run(); |
| 64 | + assertEquals(334,MORGEN.count); |
| 65 | + } |
| 66 | + |
| 67 | + @Test |
| 68 | + |
| 69 | + public void test_C6OF2H12() throws IOException, CDKException, CloneNotSupportedException { |
| 70 | + MORGEN.formula="C6OF2H12"; |
| 71 | + MORGEN.run(); |
| 72 | + assertEquals(536,MORGEN.count); |
| 73 | + } |
| 74 | + |
| 75 | + @Test |
| 76 | + |
| 77 | + public void test_C7H10() throws IOException, CDKException, CloneNotSupportedException { |
| 78 | + MORGEN.formula="C7H10"; |
| 79 | + MORGEN.run(); |
| 80 | + assertEquals(575,MORGEN.count); |
| 81 | + } |
| 82 | + |
| 83 | + @Test |
| 84 | + |
| 85 | + public void test_C6O2H12() throws IOException, CDKException, CloneNotSupportedException { |
| 86 | + MORGEN.formula="C6O2H12"; |
| 87 | + MORGEN.run(); |
| 88 | + assertEquals(1313,MORGEN.count); |
| 89 | + } |
| 90 | + |
| 91 | + @Test |
| 92 | + |
| 93 | + public void test_F2P3BrNO2H() throws IOException, CDKException, CloneNotSupportedException { |
| 94 | + MORGEN.formula="F2P3BrNO2H"; |
| 95 | + MORGEN.run(); |
| 96 | + assertEquals(1958,MORGEN.count); |
| 97 | + } |
| 98 | + |
| 99 | + @Test |
| 100 | + |
| 101 | + public void test_C6OH6() throws IOException, CDKException, CloneNotSupportedException { |
| 102 | + MORGEN.formula="C6OH6"; |
| 103 | + MORGEN.run(); |
| 104 | + assertEquals(2237,MORGEN.count); |
| 105 | + } |
| 106 | + |
| 107 | + @Test |
| 108 | + |
| 109 | + public void test_C5H6BrN() throws IOException, CDKException, CloneNotSupportedException { |
| 110 | + MORGEN.formula="C5H6BrN"; |
| 111 | + MORGEN.run(); |
| 112 | + assertEquals(2325,MORGEN.count); |
| 113 | + } |
| 114 | + |
| 115 | + @Test |
| 116 | + |
| 117 | + public void test_C6H7F2I() throws IOException, CDKException, CloneNotSupportedException { |
| 118 | + MORGEN.formula="C6H7F2I"; |
| 119 | + MORGEN.run(); |
| 120 | + assertEquals(3523,MORGEN.count); |
| 121 | + } |
| 122 | + |
| 123 | + @Test |
| 124 | + |
| 125 | + public void test_C5F2O2H2() throws IOException, CDKException, CloneNotSupportedException { |
| 126 | + MORGEN.formula="C5F2O2H2"; |
| 127 | + MORGEN.run(); |
| 128 | + assertEquals(7094,MORGEN.count); |
| 129 | + } |
| 130 | + |
| 131 | + @Test |
| 132 | + |
| 133 | + public void test_C7OH10() throws IOException, CDKException, CloneNotSupportedException { |
| 134 | + MORGEN.formula="C7OH10"; |
| 135 | + MORGEN.run(); |
| 136 | + assertEquals(7166,MORGEN.count); |
| 137 | + } |
| 138 | + |
| 139 | + @Test |
| 140 | + |
| 141 | + public void test_C4ClHF2O3() throws IOException, CDKException, CloneNotSupportedException { |
| 142 | + MORGEN.formula="C4ClHF2O3"; |
| 143 | + MORGEN.run(); |
| 144 | + assertEquals(7346,MORGEN.count); |
| 145 | + } |
| 146 | + |
| 147 | + @Test |
| 148 | + |
| 149 | + public void test_C4O5H6() throws IOException, CDKException, CloneNotSupportedException { |
| 150 | + MORGEN.formula="C4O5H6"; |
| 151 | + MORGEN.run(); |
| 152 | + assertEquals(8070,MORGEN.count); |
| 153 | + } |
| 154 | + |
| 155 | + @Test |
| 156 | + |
| 157 | + public void test_C5ClHF2O2() throws IOException, CDKException, CloneNotSupportedException { |
| 158 | + MORGEN.formula="C5ClHF2O2"; |
| 159 | + MORGEN.run(); |
| 160 | + assertEquals(12400,MORGEN.count); |
| 161 | + } |
| 162 | + |
| 163 | + @Test |
| 164 | + |
| 165 | + public void test_C5H10BrF2OP() throws IOException, CDKException, CloneNotSupportedException { |
| 166 | + MORGEN.formula="C5H10BrF2OP"; |
| 167 | + MORGEN.run(); |
| 168 | + assertEquals(15009,MORGEN.count); |
| 169 | + } |
| 170 | + |
| 171 | + @Test |
| 172 | + |
| 173 | + public void test_C9H12() throws IOException, CDKException, CloneNotSupportedException { |
| 174 | + MORGEN.formula="C9H12"; |
| 175 | + MORGEN.run(); |
| 176 | + assertEquals(19983,MORGEN.count); |
| 177 | + } |
| 178 | + |
| 179 | + @Test |
| 180 | + |
| 181 | + public void test_C6H10O2Br2() throws IOException, CDKException, CloneNotSupportedException { |
| 182 | + MORGEN.formula="C6H10O2Br2"; |
| 183 | + MORGEN.run(); |
| 184 | + assertEquals(24201,MORGEN.count); |
| 185 | + } |
| 186 | + |
| 187 | + @Test |
| 188 | + |
| 189 | + public void test_C10H16() throws IOException, CDKException, CloneNotSupportedException { |
| 190 | + MORGEN.formula="C10H16"; |
| 191 | + MORGEN.run(); |
| 192 | + assertEquals(24938,MORGEN.count); |
| 193 | + } |
| 194 | + |
| 195 | + @Test |
| 196 | + |
| 197 | + public void test_C6H6ClOI() throws IOException, CDKException, CloneNotSupportedException { |
| 198 | + MORGEN.formula="C6H6ClOI"; |
| 199 | + MORGEN.run(); |
| 200 | + assertEquals(30728,MORGEN.count); |
| 201 | + } |
| 202 | + |
| 203 | + @Test |
| 204 | + |
| 205 | + public void test_C4H5O2Br2N() throws IOException, CDKException, CloneNotSupportedException { |
| 206 | + MORGEN.formula="C4H5O2Br2N"; |
| 207 | + MORGEN.run(); |
| 208 | + assertEquals(41067,MORGEN.count); |
| 209 | + } |
| 210 | + |
| 211 | + @Test |
| 212 | + |
| 213 | + public void test_C4H10NOSP() throws IOException, CDKException, CloneNotSupportedException { |
| 214 | + MORGEN.formula="C4H10NOSP"; |
| 215 | + MORGEN.run(); |
| 216 | + assertEquals(52151,MORGEN.count); |
| 217 | + } |
| 218 | + |
| 219 | + @Test |
| 220 | + |
| 221 | + public void test_C7O2H10() throws IOException, CDKException, CloneNotSupportedException { |
| 222 | + MORGEN.formula="C7O2H10"; |
| 223 | + MORGEN.run(); |
| 224 | + assertEquals(54641,MORGEN.count); |
| 225 | + } |
| 226 | + |
| 227 | + @Test |
| 228 | + |
| 229 | + public void test_P3O3NCl2() throws IOException, CDKException, CloneNotSupportedException { |
| 230 | + MORGEN.formula="P3O3NCl2"; |
| 231 | + MORGEN.run(); |
| 232 | + assertEquals(665,MORGEN.count); |
| 233 | + } |
| 234 | + |
| 235 | + @Test |
| 236 | + |
| 237 | + public void test_C5H5SI5() throws IOException, CDKException, CloneNotSupportedException { |
| 238 | + MORGEN.formula="C5H5SI5"; |
| 239 | + MORGEN.run(); |
| 240 | + assertEquals(2619,MORGEN.count); |
| 241 | + } |
| 242 | + |
| 243 | + @Test |
| 244 | + |
| 245 | + public void test_C3O3NH5() throws IOException, CDKException, CloneNotSupportedException { |
| 246 | + MORGEN.formula="C3O3NH5"; |
| 247 | + MORGEN.run(); |
| 248 | + assertEquals(2644,MORGEN.count); |
| 249 | + } |
| 250 | + |
| 251 | + @Test |
| 252 | + |
| 253 | + public void test_C5H9ClOS() throws IOException, CDKException, CloneNotSupportedException { |
| 254 | + MORGEN.formula="C5H9ClOS"; |
| 255 | + MORGEN.run(); |
| 256 | + assertEquals(3763,MORGEN.count); |
| 257 | + } |
| 258 | + |
| 259 | + @Test |
| 260 | + |
| 261 | + public void test_C3NO2SH7() throws IOException, CDKException, CloneNotSupportedException { |
| 262 | + MORGEN.formula="C3NO2SH7"; |
| 263 | + MORGEN.run(); |
| 264 | + assertEquals(3838,MORGEN.count); |
| 265 | + } |
| 266 | + |
| 267 | + @Test |
| 268 | + |
| 269 | + public void test_C4H8Cl3O2P() throws IOException, CDKException, CloneNotSupportedException { |
| 270 | + MORGEN.formula="C4H8Cl3O2P"; |
| 271 | + MORGEN.run(); |
| 272 | + assertEquals(9313,MORGEN.count); |
| 273 | + } |
| 274 | + |
| 275 | + @Test |
| 276 | + |
| 277 | + public void test_C5H2F2SO() throws IOException, CDKException, CloneNotSupportedException { |
| 278 | + MORGEN.formula="C5H2F2SO"; |
| 279 | + MORGEN.run(); |
| 280 | + assertEquals(13446,MORGEN.count); |
| 281 | + } |
| 282 | + |
| 283 | + @Test |
| 284 | + |
| 285 | + public void test_C7H11ClS() throws IOException, CDKException, CloneNotSupportedException { |
| 286 | + MORGEN.formula="C7H11ClS"; |
| 287 | + MORGEN.run(); |
| 288 | + assertEquals(15093,MORGEN.count); |
| 289 | + } |
| 290 | + |
| 291 | + @Test |
| 292 | + |
| 293 | + public void test_C4NO3H7() throws IOException, CDKException, CloneNotSupportedException { |
| 294 | + MORGEN.formula="C4NO3H7"; |
| 295 | + MORGEN.run(); |
| 296 | + assertEquals(18469,MORGEN.count); |
| 297 | + } |
| 298 | + |
| 299 | + @Test |
| 300 | + |
| 301 | + public void test_C4H5O2F2P() throws IOException, CDKException, CloneNotSupportedException { |
| 302 | + MORGEN.formula="C4H5O2F2P"; |
| 303 | + MORGEN.run(); |
| 304 | + assertEquals(41067,MORGEN.count); |
| 305 | + } |
| 306 | + |
| 307 | + @Test |
| 308 | + |
| 309 | + public void test_C3N3O2H7() throws IOException, CDKException, CloneNotSupportedException { |
| 310 | + MORGEN.formula="C3N3O2H7"; |
| 311 | + MORGEN.run(); |
| 312 | + assertEquals(45626,MORGEN.count); |
| 313 | + } |
| 314 | + |
| 315 | + @Test |
| 316 | + |
| 317 | + public void test_C5N3H9() throws IOException, CDKException, CloneNotSupportedException { |
| 318 | + MORGEN.formula="C5N3H9"; |
| 319 | + MORGEN.run(); |
| 320 | + assertEquals(46125,MORGEN.count); |
| 321 | + } |
| 322 | + |
| 323 | + @Test |
| 324 | + |
| 325 | + public void test_C3O6PH5() throws IOException, CDKException, CloneNotSupportedException { |
| 326 | + MORGEN.formula="C3O6PH5"; |
| 327 | + MORGEN.run(); |
| 328 | + assertEquals(51323,MORGEN.count); |
| 329 | + } |
| 330 | + |
| 331 | + @Test |
| 332 | + |
| 333 | + public void test_C5H5POBr2() throws IOException, CDKException, CloneNotSupportedException { |
| 334 | + MORGEN.formula="C5H5POBr2"; |
| 335 | + MORGEN.run(); |
| 336 | + assertEquals(62886,MORGEN.count); |
| 337 | + } |
| 338 | + |
| 339 | + |
| 340 | + |
| 341 | +} |
0 commit comments