@Test
public void testNN_dimethylaniline_cation() throws Exception {

    IAtomContainer mol = null;
    String filename = "data/mdl/NN_dimethylaniline.mol";
    InputStream ins = this.getClass().getClassLoader().getResourceAsStream(filename);
    MDLV2000Reader reader = new MDLV2000Reader(ins);
    IChemFile chemFile = (IChemFile) reader.read((ChemObject) new ChemFile());
    mol = chemFile.getChemSequence(0).getChemModel(0).getMoleculeSet().getAtomContainer(0);
    AtomContainerManipulator.percieveAtomTypesAndConfigureAtoms(mol);
    addImplicitHydrogens(mol);
    lpcheck.saturate(mol);
    Aromaticity.cdkLegacy().apply(mol);
    IAtomContainerSet acSet = ConjugatedPiSystemsDetector.detect(mol);
    Assert.assertEquals(1, acSet.getAtomContainerCount());
    IAtomContainer ac1 = acSet.getAtomContainer(0);
    Assert.assertEquals(6, ac1.getAtomCount());
    Assert.assertEquals(5, ac1.getBondCount());
}