Esempio n. 1
0
  @Test
  public void testCyclohexaneWithHydrogens() {
    IAtomContainer cyclohexane = MoleculeFactory.makeCyclohexane();
    for (int i = 0; i < 6; i++) {
      addHydrogens(cyclohexane, cyclohexane.getAtom(i), 2);
    }
    String expected =
        "[C]([C]([C]([C,0]([H][H])[H][H])[H][H])" + "[C]([C]([C,0][H][H])[H][H])[H][H])";

    String actual = this.canonicalStringFromMolecule(cyclohexane);
    Assert.assertEquals(expected, actual);
  }