JAL-1213 JAL-674 - import a PDB file using Jmol data api and decorate any peptide...
[jalview.git] / test / jalview / ext / jmol / PDBFileWithJmolTest.java
diff --git a/test/jalview/ext/jmol/PDBFileWithJmolTest.java b/test/jalview/ext/jmol/PDBFileWithJmolTest.java
new file mode 100644 (file)
index 0000000..2b53822
--- /dev/null
@@ -0,0 +1,31 @@
+/**
+ * 
+ */
+package jalview.ext.jmol;
+
+import static org.junit.Assert.*;
+
+import java.util.Vector;
+
+import jalview.datamodel.SequenceI;
+
+import org.junit.Test;
+
+/**
+ * @author jimp
+ *
+ */
+public class PDBFileWithJmolTest
+{
+
+  @Test
+  public void test() throws Exception
+  {
+    PDBFileWithJmol jtest=new PDBFileWithJmol("./examples/1vsp", jalview.io.AppletFormatAdapter.FILE);
+    Vector<SequenceI> seqs=jtest.getSeqs();
+    assertTrue("No sequences extracted from testfile", seqs!=null && seqs.size()>0);
+    assertTrue("No annotation generated.", seqs.get(0).getAnnotation()!=null && seqs.get(0).getAnnotation().length!=0);
+    
+  }
+
+}