JAL-2507 - required callers to specify exact ignore flags for StockholmFileTest.testA...
authorJim Procter <jprocter@issues.jalview.org>
Mon, 15 May 2017 15:43:12 +0000 (16:43 +0100)
committerJim Procter <jprocter@issues.jalview.org>
Mon, 15 May 2017 15:43:12 +0000 (16:43 +0100)
test/jalview/io/AnnotationFileIOTest.java
test/jalview/io/PhylipFileTests.java
test/jalview/io/RNAMLfileTest.java
test/jalview/io/StockholmFileTest.java
test/jalview/ws/jabaws/DisorderAnnotExportImport.java
test/jalview/ws/jabaws/JpredJabaStructExportImport.java
test/jalview/ws/jabaws/RNAStructExportImport.java

index c3aa13e..62bd0b9 100644 (file)
@@ -153,7 +153,8 @@ public class AnnotationFileIOTest
                       DataSourceType.PASTE));
 
       // test for consistency in io
-      StockholmFileTest.testAlignmentEquivalence(al, al_new, false);
+      StockholmFileTest.testAlignmentEquivalence(al, al_new, false, false,
+              false);
       return;
     } catch (Exception e)
     {
index f99c67a..d853350 100644 (file)
@@ -190,7 +190,8 @@ public class PhylipFileTests
             DataSourceType.PASTE, FileFormat.Phylip);
     assertNotNull("Couldn't parse reimported alignment data.", al_input);
 
-    StockholmFileTest.testAlignmentEquivalence(al, al_input, false);
+    StockholmFileTest.testAlignmentEquivalence(al, al_input, false, false,
+            false);
 
   }
 }
index 1c54980..ae72de4 100644 (file)
@@ -53,7 +53,7 @@ public class RNAMLfileTest
   {
     StockholmFileTest.testFileIOwithFormat(new File(
             "examples/testdata/rna-alignment.xml"), FileFormat.Stockholm,
-            -1, -1, true);
+            -1, -1, true, true, true);
 
   }
 
index 1a18fb9..228c935 100644 (file)
@@ -60,7 +60,7 @@ public class StockholmFileTest
   public void pfamFileIO() throws Exception
   {
     testFileIOwithFormat(new File(PfamFile), FileFormat.Stockholm, -1, 0,
-            false);
+            false, false, false);
   }
 
   @Test(groups = { "Functional" })
@@ -86,7 +86,7 @@ public class StockholmFileTest
   public void rfamFileIO() throws Exception
   {
     testFileIOwithFormat(new File(RfamFile), FileFormat.Stockholm, 2, 1,
-            false);
+            false, false, false);
   }
 
   /**
@@ -98,11 +98,14 @@ public class StockholmFileTest
    * @param ioformat
    *          - label for IO class used to write and read back in the data from
    *          f
+   * @param ignoreFeatures
    * @param ignoreRowVisibility
+   * @param allowNullAnnotations
    */
 
   public static void testFileIOwithFormat(File f, FileFormatI ioformat,
-          int naliannot, int nminseqann, boolean ignoreRowVisibility)
+          int naliannot, int nminseqann, boolean ignoreFeatures,
+          boolean ignoreRowVisibility, boolean allowNullAnnotations)
   {
     System.out.println("Reading file: " + f);
     String ff = f.getPath();
@@ -136,7 +139,8 @@ public class StockholmFileTest
               "Identify routine could not recognise output generated by '"
                       + ioformat + "' writer",
               ioformat.equals(identifyoutput));
-      testAlignmentEquivalence(al, al_input, false);
+      testAlignmentEquivalence(al, al_input, ignoreFeatures,
+              ignoreRowVisibility, allowNullAnnotations);
       int numaliannot = 0, numsqswithali = 0;
       for (AlignmentAnnotation ala : al_input.getAlignmentAnnotation())
       {
index 2714d6c..e8b6c2b 100644 (file)
@@ -177,7 +177,8 @@ public class DisorderAnnotExportImport
                       DataSourceType.PASTE));
 
       // test for consistency in io
-      StockholmFileTest.testAlignmentEquivalence(al, al_new, true);
+      StockholmFileTest.testAlignmentEquivalence(al, al_new, true, false,
+              false);
       return;
     } catch (Exception e)
     {
index d5b6ed1..8326687 100644 (file)
@@ -218,7 +218,8 @@ public class JpredJabaStructExportImport
                       DataSourceType.PASTE));
 
       // test for consistency in io
-      StockholmFileTest.testAlignmentEquivalence(al, al_new, false);
+      StockholmFileTest.testAlignmentEquivalence(al, al_new, false, false,
+              false);
       return;
     } catch (Exception e)
     {
index 4e9741e..5ea97ff 100644 (file)
@@ -242,7 +242,8 @@ public class RNAStructExportImport
                       DataSourceType.PASTE));
 
       // test for consistency in io
-      StockholmFileTest.testAlignmentEquivalence(al, al_new, false);
+      StockholmFileTest.testAlignmentEquivalence(al, al_new, false, false,
+              false);
       return;
     } catch (Exception e)
     {