Skip to content

Commit

Permalink
Fixed error from changes in API
Browse files Browse the repository at this point in the history
Solves bug 3051
  • Loading branch information
goglepox committed Jun 12, 2012
1 parent f44b469 commit 5fb8318
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 15 deletions.
Expand Up @@ -10,30 +10,23 @@
******************************************************************************/
package net.bioclipse.cdk.ui.tests;

import static org.junit.Assert.*;
import static org.junit.Assert.assertFalse;
import static org.junit.Assert.assertTrue;

import java.io.IOException;
import java.io.InputStream;
import java.lang.reflect.InvocationTargetException;
import java.net.MalformedURLException;
import java.net.URI;
import java.net.URISyntaxException;
import java.net.URL;
import java.util.ArrayList;
import java.util.List;

import net.bioclipse.cdk.business.Activator;
import net.bioclipse.cdk.business.ICDKManager;
import net.bioclipse.cdk.domain.ICDKMolecule;
import net.bioclipse.cdk.ui.filters.FilterOutSalts;
import net.bioclipse.cdk.ui.handlers.ConvertSMILEStoSDF;
import net.bioclipse.core.MockIFile;
import net.bioclipse.core.business.BioclipseException;

import org.eclipse.core.runtime.CoreException;
import org.eclipse.core.runtime.FileLocator;
import org.eclipse.core.runtime.NullProgressMonitor;
import org.junit.Assert;
import org.junit.Test;

/**
Expand Down Expand Up @@ -62,8 +55,7 @@ public void testFilterOutSalts() throws MalformedURLException, IOException, Bioc

//Remove salts
//FIXME The next line does not compile
// FilterOutSalts.filterOutSalts(mols, new NullProgressMonitor());
Assert.fail();
new FilterOutSalts().applyFilter( mols, new NullProgressMonitor() );
//Assert we have NO salts in all mols
for (ICDKMolecule mol : mols){
assertTrue(cdk.isConnected(mol));
Expand Down
Expand Up @@ -99,7 +99,7 @@ protected IStatus run(IProgressMonitor monitor) {
protected abstract String getFilterName();

protected abstract List<ICDKMolecule> applyFilter(List<ICDKMolecule> mols,
SubProgressMonitor subProgressMonitor);
IProgressMonitor subProgressMonitor );


}
Expand Down
Expand Up @@ -9,7 +9,7 @@
import net.bioclipse.core.business.BioclipseException;

import org.apache.log4j.Logger;
import org.eclipse.core.runtime.SubProgressMonitor;
import org.eclipse.core.runtime.IProgressMonitor;
import org.openscience.cdk.interfaces.IAtomContainer;

/**
Expand All @@ -28,8 +28,8 @@ protected String getFilterName() {
}

@Override
protected List<ICDKMolecule> applyFilter(List<ICDKMolecule> mols,
SubProgressMonitor monitor) {
public List<ICDKMolecule> applyFilter( List<ICDKMolecule> mols,
IProgressMonitor monitor ) {

ICDKManager cdk = Activator.getDefault().getJavaCDKManager();

Expand Down

0 comments on commit 5fb8318

Please sign in to comment.