X-Git-Url: http://source.jalview.org/gitweb/?a=blobdiff_plain;f=test%2Fjalview%2Fio%2FFormatAdapterTest.java;h=d63fb70966443b5a0175e9416b9f9329d32e4ad1;hb=d043ce47fc710d3eb2629ba926a8a7417bd67d8c;hp=8f3ad2f58fa5aab03e978cce2d9a07e729c2c5e9;hpb=04c8f7bff663aa469127e9eed4164e02933782f1;p=jalview.git diff --git a/test/jalview/io/FormatAdapterTest.java b/test/jalview/io/FormatAdapterTest.java index 8f3ad2f..d63fb70 100644 --- a/test/jalview/io/FormatAdapterTest.java +++ b/test/jalview/io/FormatAdapterTest.java @@ -56,8 +56,17 @@ public class FormatAdapterTest { try { - AlignmentI al = new FormatAdapter().readFile("examples/uniref50.fa", + AlignmentI al; + if (format == FileFormat.HMMER3) + { + al = new FormatAdapter().readFile("examples/uniref50.hmm", + DataSourceType.FILE, FileFormat.HMMER3); + } + else + { + al = new FormatAdapter().readFile("examples/uniref50.fa", DataSourceType.FILE, FileFormat.Fasta); + } /* * 'gap' is the gap character used in the alignment data file here, @@ -73,8 +82,9 @@ public class FormatAdapterTest AlignmentI reloaded = new FormatAdapter().readFile(formatted, DataSourceType.PASTE, format); List reread = reloaded.getSequences(); - assertEquals("Wrong number of reloaded sequences", seqs.length, - reread.size()); + assertEquals("Wrong number of reloaded sequences", seqs.length, + reread.size()); + int i = 0; for (SequenceI seq : reread) @@ -130,7 +140,7 @@ public class FormatAdapterTest @DataProvider(name = "formats") static Object[][] getFormats() { - List both = new ArrayList(); + List both = new ArrayList<>(); for (FileFormatI format : FileFormats.getInstance().getFormats()) { if (format.isReadable() && format.isWritable()