	@Test
	public void testConvertSpareValenciesToDoubleBonds() throws StructureBuildingException{

		Fragment dhp = fm.buildSMILES("c1cCccC1");
		FragmentTools.convertSpareValenciesToDoubleBonds(dhp);
		for(Atom a : dhp.getAtomList()) {
			assertEquals("All atoms have no sv", false, a.hasSpareValency());
		}
		Fragment funnydiene = fm.buildSMILES("C(=C)C=C");
		FragmentTools.convertSpareValenciesToDoubleBonds(funnydiene);
		for(Atom a : funnydiene.getAtomList()) {
			assertEquals("All atoms have no sv", false, a.hasSpareValency());
		}
		Fragment naphthalene = fm.buildSMILES("c1cccc2ccccc12");
		FragmentTools.convertSpareValenciesToDoubleBonds(naphthalene);
		for(Atom a : naphthalene.getAtomList()) {
			assertEquals("All atoms have no sv", false, a.hasSpareValency());
		}
		Fragment pentalene = fm.buildSMILES("c12c(ccc1)ccc2");
		for(Atom a : pentalene.getAtomList()) {
			assertEquals("All atoms have sv", true, a.hasSpareValency());
		}
		FragmentTools.convertSpareValenciesToDoubleBonds(pentalene);
		for(Atom a : pentalene.getAtomList()) {
			assertEquals("All atoms have no sv", false, a.hasSpareValency());
		}

	}