@Test
public void testCompareBitSetandBitFingerprintTanimoto() throws Exception {

    IAtomContainer mol1 = TestMoleculeFactory.make123Triazole();
    IAtomContainer mol2 = TestMoleculeFactory.makeImidazole();
    Fingerprinter fingerprinter = new Fingerprinter(1024, 8);
    BitSet bs1 = fingerprinter.getBitFingerprint(mol1).asBitSet();
    BitSet bs2 = fingerprinter.getBitFingerprint(mol2).asBitSet();
    float tanimoto = Tanimoto.calculate(bs1, bs2);
    BitSetFingerprint fp1 = new BitSetFingerprint(bs1);
    BitSetFingerprint fp2 = new BitSetFingerprint(bs2);
    double tanimoto2 = Tanimoto.calculate(fp1, fp2);
    Assert.assertEquals(tanimoto, tanimoto2, 0.01);
    IntArrayFingerprint ifp1 = new IntArrayFingerprint(fp1);
    IntArrayFingerprint ifp2 = new IntArrayFingerprint(fp2);
    tanimoto2 = Tanimoto.calculate(ifp1, ifp2);
    Assert.assertEquals(tanimoto, tanimoto2, 0.01);
}