import java.io.StringReader;
import java.util.List;
+import javax.xml.parsers.ParserConfigurationException;
+
import org.junit.Test;
+import org.xml.sax.SAXException;
+
+import fr.orsay.lri.varna.exceptions.ExceptionFileFormatOrSyntax;
+import fr.orsay.lri.varna.exceptions.ExceptionLoadingFailed;
+import fr.orsay.lri.varna.exceptions.ExceptionPermissionDenied;
public class TCoffeeScoreFileTest {
final static File ALIGN_FILE = new File("test/jalview/io/tcoffee.fasta_aln");
@Test
- public void testReadHeader() throws IOException, FileNotFoundException {
+ public void testReadHeader() throws IOException, FileNotFoundException, ExceptionFileFormatOrSyntax, ParserConfigurationException, SAXException, ExceptionPermissionDenied, ExceptionLoadingFailed {
TCoffeeScoreFile scoreFile = new TCoffeeScoreFile(SCORE_FILE.getPath(),AppletFormatAdapter.FILE);
assertTrue(scoreFile.getWarningMessage(),scoreFile.isValid());
@Test
- public void testWrongFile() {
+ public void testWrongFile() throws ExceptionFileFormatOrSyntax, ParserConfigurationException, SAXException, ExceptionPermissionDenied, ExceptionLoadingFailed {
try {
TCoffeeScoreFile result = new TCoffeeScoreFile(ALIGN_FILE.getPath(), FormatAdapter.FILE);
assertFalse(result.isValid());
}
@Test
- public void testHeightAndWidth() throws IOException {
+ public void testHeightAndWidth() throws IOException, ExceptionFileFormatOrSyntax, ParserConfigurationException, SAXException, ExceptionPermissionDenied, ExceptionLoadingFailed {
TCoffeeScoreFile result = new TCoffeeScoreFile(SCORE_FILE.getPath(), FormatAdapter.FILE);
assertTrue(result.isValid());
assertEquals( 8, result.getHeight() );
}
@Test
- public void testParse() throws IOException {
+ public void testParse() throws IOException, ExceptionFileFormatOrSyntax, ParserConfigurationException, SAXException, ExceptionPermissionDenied, ExceptionLoadingFailed {
TCoffeeScoreFile parser = new TCoffeeScoreFile(SCORE_FILE.getPath(), FormatAdapter.FILE);
@Test
- public void testGetAsList() throws IOException {
+ public void testGetAsList() throws IOException, ExceptionFileFormatOrSyntax, ParserConfigurationException, SAXException, ExceptionPermissionDenied, ExceptionLoadingFailed {
TCoffeeScoreFile parser = new TCoffeeScoreFile(SCORE_FILE.getPath(),FormatAdapter.FILE);
assertTrue(parser.getWarningMessage(),parser.isValid());
@Test
- public void testGetAsArray() throws IOException {
+ public void testGetAsArray() throws IOException, ExceptionFileFormatOrSyntax, ParserConfigurationException, SAXException, ExceptionPermissionDenied, ExceptionLoadingFailed {
TCoffeeScoreFile parser = new TCoffeeScoreFile(SCORE_FILE.getPath(),FormatAdapter.FILE);
assertTrue(parser.getWarningMessage(),parser.isValid());