@Test
public void testWriteMolecule() throws Exception {

    BasicConfigurator.configure();
    Logger.getRootLogger().setLevel(Level.ERROR);
    StringWriter output = new StringWriter();
    CDKOWLWriter writer = new CDKOWLWriter(output);
    IAtomContainer mol = DefaultChemObjectBuilder.getInstance().newInstance(IAtomContainer.class);
    mol.addAtom(new Atom("C"));
    mol.addAtom(new Atom("C"));
    mol.addBond(0, 1, IBond.Order.DOUBLE);
    writer.write(mol);
    writer.close();
    String outputString = output.toString();
    Assert.assertTrue(outputString.contains("http://cdk.sourceforge.net/model.owl#"));
}