JAL-629 changes merged in from develop fixed it. Deleted duplicate example PAE file.
[jalview.git] / test / jalview / ws / dbsources / EBIAlphaFoldTest.java
index b737042..8cba8ab 100644 (file)
@@ -12,7 +12,10 @@ import org.testng.annotations.BeforeClass;
 import org.testng.annotations.DataProvider;
 import org.testng.annotations.Test;
 
+import jalview.datamodel.Alignment;
+import jalview.datamodel.AlignmentI;
 import jalview.datamodel.Sequence;
+import jalview.datamodel.SequenceI;
 import jalview.gui.Desktop;
 import jalview.gui.JvOptionPane;
 import jalview.structure.StructureMapping;
@@ -32,11 +35,13 @@ public class EBIAlphaFoldTest
   @DataProvider(name = "getExamplePAEfiles")
   public Object[][] getExamplePAEfiles()
   {
-    return new String[][] { {
-        "examples/test_fab41.result/test_fab41_predicted_aligned_error_v1.json" },
+    return new String[][] {
+        //
+        { "examples/test_fab41.result/test_fab41_predicted_aligned_error_v1.json" },
         { "examples/AlphaFold/AF-A0A1U8FD60-F1-predicted_aligned_error_v4.json" },
         { "examples/AlphaFold/AF-Q5VSL9-F1-predicted_aligned_error_v4.json" },
-        { "examples/AlphaFold/AF-Q5VSL9-F1-predicted_aligned_error_v4_2023.json" } };
+        //
+    };
   }
 
   @Test(groups = { "Functional" }, dataProvider = "getExamplePAEfiles")
@@ -62,8 +67,13 @@ public class EBIAlphaFoldTest
       FileAssert.assertFile(new File(paeFile),
               "Test file '" + paeFile + "' doesn't seem to exist");
     }
+    SequenceI seq = new Sequence("Dummy/1-2000", "ASDASDA");
+    AlignmentI al = new Alignment(new SequenceI[] { seq });
     StructureSelectionManager ssm = StructureSelectionManager
             .getStructureSelectionManager(Desktop.instance);
+    StructureMapping sm = new StructureMapping(seq, pdbFile, null, null,
+            null, null);
+    ssm.addStructureMapping(sm);
 
     StructureMapping[] smArray = ssm.getMapping(pdbFile);
 
@@ -75,7 +85,7 @@ public class EBIAlphaFoldTest
               "Import of '" + paeFile + "' didn't complete successfully");
     } catch (IOException | ParseException e)
     {
-      e.printStackTrace();
+      Assert.fail("Exception importing paefile '" + paeFile + "'", e);
     }
   }
 
@@ -86,15 +96,13 @@ public class EBIAlphaFoldTest
         //
         /*
          */
-        { "examples/test_fab41.result/sample.a2m",
-            "examples/test_fab41.result/test_fab41_predicted_aligned_error_v1.json" },
-        /*
+        { "examples/test_fab41.result/test_fab41_unrelaxed_rank_1_model_3.pdb",
+            "examples/test_fab41.result/test_fab41_unrelaxed_rank_1_model_3_scores.json" },
         { "examples/AlphaFold/AF-A0A1U8FD60-F1-model_v4.pdb",
             "examples/AlphaFold/AF-A0A1U8FD60-F1-predicted_aligned_error_v4.json" },
         { "examples/AlphaFold/AF-Q5VSL9-F1-model_v4.pdb",
             "examples/AlphaFold/AF-Q5VSL9-F1-predicted_aligned_error_v4.json" },
-        { "examples/AlphaFold/AF-Q5VSL9-F1-model_v4.pdb",
-            "examples/AlphaFold/AF-Q5VSL9-F1-predicted_aligned_error_v4_2023.json" },
+        /*
          */
     };
   }