import static org.junit.Assert.assertNotNull;
import static org.junit.Assert.assertTrue;
import static org.junit.Assert.fail;
+import jalview.datamodel.AlignmentAnnotation;
+import jalview.datamodel.AlignmentI;
+import jalview.gui.Jalview2XML;
+import jalview.io.AnnotationFile;
+import jalview.io.FormatAdapter;
+import jalview.io.StockholmFileTest;
+import jalview.ws.jws2.Jws2Discoverer;
+import jalview.ws.jws2.RNAalifoldClient;
+import jalview.ws.jws2.SequenceAnnotationWSClient;
+import jalview.ws.jws2.jabaws2.Jws2Instance;
+import jalview.ws.params.AutoCalcSetting;
import java.awt.Component;
import java.util.ArrayList;
import javax.swing.JMenuItem;
import org.junit.AfterClass;
+import org.junit.Assert;
import org.junit.BeforeClass;
import org.junit.Test;
import compbio.metadata.WrongParameterException;
-import jalview.datamodel.AlignmentI;
-import jalview.gui.Jalview2XML;
-import jalview.io.AnnotationFile;
-import jalview.io.FormatAdapter;
-import jalview.io.StockholmFileTest;
-import jalview.ws.jws2.Jws2Discoverer;
-import jalview.ws.jws2.RNAalifoldClient;
-import jalview.ws.jws2.SequenceAnnotationWSClient;
-import jalview.ws.jws2.jabaws2.Jws2Instance;
-import jalview.ws.params.AutoCalcSetting;
-
public class RNAStructExportImport
{
- public static String testseqs = "examples/unfolded_RF00031.aln";
+ public static String testseqs = "examples/RF00031_folded.stk";
public static Jws2Discoverer disc;
assertNotNull("Couldn't load test data ('" + testseqs + "')", af);
+ // remove any existing annotation
+ List<AlignmentAnnotation> aal = new ArrayList<AlignmentAnnotation>();
+ for (AlignmentAnnotation rna : af.getViewport().getAlignment()
+ .getAlignmentAnnotation())
+ {
+ if (rna.isRNA())
+ {
+ aal.add(rna);
+ }
+ }
+ for (AlignmentAnnotation rna : aal)
+ {
+ af.getViewport().getAlignment().deleteAnnotation(rna);
+ }
+ af.getViewport().alignmentChanged(af.alignPanel); // why is af.alignPanel
+ // public?
}
@AfterClass